From 5668959399dc953bb59b28e46690e51066d6ab3d Mon Sep 17 00:00:00 2001 From: Carlos Perilla Date: Tue, 11 Aug 2009 19:09:51 -0500 Subject: Let users join and drop group membership from xmpp --- lib/commandinterpreter.php | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'lib/commandinterpreter.php') diff --git a/lib/commandinterpreter.php b/lib/commandinterpreter.php index ac6bf73c8..6e4340e5d 100644 --- a/lib/commandinterpreter.php +++ b/lib/commandinterpreter.php @@ -70,6 +70,26 @@ class CommandInterpreter } else { return new OffCommand($user); } + case 'join': + if (!$arg) { + return null; + } + list($other, $extra) = explode(' ', $arg, 2); + if ($extra) { + return null; + } else { + return new JoinCommand($user, $other); + } + case 'drop': + if (!$arg) { + return null; + } + list($other, $extra) = explode(' ', $arg, 2); + if ($extra) { + return null; + } else { + return new DropCommand($user, $other); + } case 'follow': case 'sub': if (!$arg) { -- cgit v1.2.3