summaryrefslogtreecommitdiff
path: root/classes/Command.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2008-10-04 12:32:13 -0400
committerEvan Prodromou <evan@controlyourself.ca>2008-10-04 12:32:13 -0400
commitf072147e4e538b6851e3056fe9ff84952424c828 (patch)
tree0a35402e891208adc504d129102fc4527afb1b1e /classes/Command.php
parentc8fd8fa00f30cb2862a6feb32bc1b7d3a394c565 (diff)
add channels and use command interpreter in different channels
darcs-hash:20081004163213-5ed1f-684ecb464e843b1bbe456c348e56b40a39a83ecd.gz
Diffstat (limited to 'classes/Command.php')
-rw-r--r--classes/Command.php12
1 files changed, 10 insertions, 2 deletions
diff --git a/classes/Command.php b/classes/Command.php
index 1a6d7cc06..3e2afec6c 100644
--- a/classes/Command.php
+++ b/classes/Command.php
@@ -299,7 +299,11 @@ class OffCommand extends Command {
if ($other) {
$channel->error($this->user, _("Command not yet implemented."));
} else {
- $channel->off($this->user);
+ if ($channel->off($this->user)) {
+ $channel->output(_('Notification off.'));
+ } else {
+ $channel->error(_('Can\'t turn off notification.'));
+ }
}
}
}
@@ -315,7 +319,11 @@ class OnCommand extends Command {
if ($other) {
$channel->error($this->user, _("Command not yet implemented."));
} else {
- $channel->on($this->user);
+ if ($channel->on($this->user)) {
+ $channel->output(_('Notification on.'));
+ } else {
+ $channel->error(_('Can\'t turn on notification.'));
+ }
}
}
}