diff options
author | Kevin Smith <git@kismith.co.uk> | 2012-07-21 18:15:37 (GMT) |
---|---|---|
committer | Kevin Smith <git@kismith.co.uk> | 2012-07-21 18:56:03 (GMT) |
commit | 12024c66fe21c62b158552abe26b1bcfa142ffe8 (patch) | |
tree | cfedc6e34b147bbb05fedfd69eeaad27bd5eadbd /Swiftob/Swiftob.cpp | |
parent | 2a690f23a71f5f24550df112e0544b32826655db (diff) | |
download | swift-contrib-12024c66fe21c62b158552abe26b1bcfa142ffe8.zip swift-contrib-12024c66fe21c62b158552abe26b1bcfa142ffe8.tar.bz2 |
Allowing generic message listeners for Swiftob bots
Diffstat (limited to 'Swiftob/Swiftob.cpp')
-rw-r--r-- | Swiftob/Swiftob.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Swiftob/Swiftob.cpp b/Swiftob/Swiftob.cpp index 331e55e..6f36b3d 100644 --- a/Swiftob/Swiftob.cpp +++ b/Swiftob/Swiftob.cpp @@ -87,6 +87,10 @@ void Swiftob::handleMessageReceived(Swift::Message::ref message) { std::cout << "Not handling empty body" << std::endl; return; } + + /* Run through any full-message listeners */ + commands_->runListeners(message); + /*Convert body into !command if it's not a MUC, and it misses the bang*/ std::string bangBody(body); if (type != Swift::Message::Groupchat && body[0] != '!') { |