diff options
| author | 2025-03-18 13:12:28 +0000 | |
|---|---|---|
| committer | 2025-03-18 13:12:28 +0000 | |
| commit | 8adda0dca4cb94be6a071e67b3e3c89a22375aca (patch) | |
| tree | e68839d6da2df39b3ba43a8665e44a9a98c6c16c /src/modules/m_disable.cpp | |
| parent | Skip lines which are empty in mkheaders. (diff) | |
Add a formatting overload of the ModuleException constructor.
Diffstat (limited to 'src/modules/m_disable.cpp')
| -rw-r--r-- | src/modules/m_disable.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/modules/m_disable.cpp b/src/modules/m_disable.cpp index 20092ae75..02326a417 100644 --- a/src/modules/m_disable.cpp +++ b/src/modules/m_disable.cpp @@ -47,14 +47,14 @@ private: { // Check that the character is a valid mode letter. if (!ModeParser::IsModeChar(chr)) - throw ModuleException(this, INSP_FORMAT("Invalid mode '{}' was specified in <disabled:{}> at {}", - chr, field, tag->source.str())); + throw ModuleException(this, "Invalid mode '{}' was specified in <disabled:{}> at {}", + chr, field, tag->source.str()); // Check that the mode actually exists. ModeHandler* mh = ServerInstance->Modes.FindMode(chr, type); if (!mh) - throw ModuleException(this, INSP_FORMAT("Nonexistent mode '{}' was specified in <disabled:{}> at {}", - chr, field, tag->source.str())); + throw ModuleException(this, "Nonexistent mode '{}' was specified in <disabled:{}> at {}", + chr, field, tag->source.str()); // Disable the mode. ServerInstance->Logs.Debug(MODNAME, "The {} ({}) {} mode has been disabled", @@ -90,8 +90,8 @@ public: // Check that the command actually exists. Command* handler = ServerInstance->Parser.GetHandler(command); if (!handler) - throw ModuleException(this, INSP_FORMAT("Nonexistent command '{}' was specified in <disabled:commands> at {}", - command, tag->source.str())); + throw ModuleException(this, "Nonexistent command '{}' was specified in <disabled:commands> at {}", + command, tag->source.str()); // Prevent admins from disabling MODULES for transparency reasons. if (handler->name == "MODULES") |
