diff options
author | Attila Molnar <attilamolnar@hush.com> | 2014-02-23 12:24:14 +0100 |
---|---|---|
committer | Attila Molnar <attilamolnar@hush.com> | 2014-02-23 12:24:14 +0100 |
commit | 5a64433015f5a25af133a136468093a140595bc5 (patch) | |
tree | d9486e1384201441e77ad522534f6225326f3664 /include | |
parent | 3c9e626d3f497af384b3248065221bf0af3631c5 (diff) |
Throw an exception if ModeParser::AddMode() fails
Diffstat (limited to 'include')
-rw-r--r-- | include/mode.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/mode.h b/include/mode.h index c257226c9..7c5682135 100644 --- a/include/mode.h +++ b/include/mode.h @@ -637,10 +637,12 @@ class CoreExport ModeParser const std::string& GetLastParse() const { return LastParse; } const std::vector<std::string>& GetLastParseParams() { return LastParseParams; } const std::vector<TranslateType>& GetLastParseTranslate() { return LastParseTranslate; } + /** Add a mode to the mode parser. - * @return True if the mode was successfully added. + * Throws a ModuleException if the mode cannot be added. */ - bool AddMode(ModeHandler* mh); + void AddMode(ModeHandler* mh); + /** Delete a mode from the mode parser. * When a mode is deleted, the mode handler will be called * for every user (if it is a user mode) or for every channel |