projects
/
docbot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3968a7b
)
- verify if commandchannel is joined, before posting something
author
Andreas Scherbaum
<andreas@scherbaum.biz>
Sat, 19 May 2012 21:32:43 +0000
(23:32 +0200)
committer
Andreas Scherbaum
<andreas@scherbaum.biz>
Sat, 19 May 2012 21:32:43 +0000
(23:32 +0200)
docbot.pl
patch
|
blob
|
blame
|
history
diff --git
a/docbot.pl
b/docbot.pl
index 26afe0906f7a9e4869014bad72c9aaaf91b69bae..686eb1bb410df21a93c6d4235972872a3e428dae 100755
(executable)
--- a/
docbot.pl
+++ b/
docbot.pl
@@
-928,6
+928,12
@@
sub send_to_commandchannel {
my $commandchannel = config_get_key2('bot', 'commandchannel');
+ if (!session_for_channel($commandchannel)) {
+ print_msg("commandchannel: $msg", DEBUG);
+ print_msg("commandchannel ($commandchannel) not joined!", ERROR);
+ return;
+ }
+
print_msg("commandchannel: $msg", DEBUG);
send_to_channel(config_get_key2('bot', 'commandchannel'), $msg)
}