+ // Get the content of the message
+ $event = $this->getEvent();
+ $msg = trim($event->getText());
+ $prefix = $this->getConfig('command.prefix');
+
+ // Check for the command prefix if one is set and needed
+ if ($prefix && $event->isInChannel()) {
+ if (strpos($msg, $prefix) !== 0) {
+ return;
+ } else {
+ $msg = substr($msg, strlen($prefix));
+ }