]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
move mention detection before default in OStatusPlugin
authorEvan Prodromou <evan@status.net>
Tue, 23 Feb 2010 20:59:10 +0000 (15:59 -0500)
committerEvan Prodromou <evan@status.net>
Tue, 23 Feb 2010 20:59:10 +0000 (15:59 -0500)
plugins/OStatus/OStatusPlugin.php

index db4a0af358f8e3c714d7897832696191916c4259..679857f897aa7f32f0c739cabdb23eedb309e1b4 100644 (file)
@@ -224,7 +224,7 @@ class OStatusPlugin extends Plugin
      *
      */
 
-    function onEndFindMentions($sender, $text, &$mentions)
+    function onStartFindMentions($sender, $text, &$mentions)
     {
         preg_match_all('/(?:^|\s+)@((?:\w+\.)*\w+@(?:\w+\.)*\w+(?:\w+\-\w+)*\.\w+)/',
                        $text,
@@ -464,14 +464,13 @@ class OStatusPlugin extends Plugin
         $oprofile = Ostatus_profile::staticGet('group_id', $group->id);
         if ($oprofile) {
             // Drop the PuSH subscription if there are no other subscribers.
-    
+
             $members = $group->getMembers(0, 1);
             if ($members->N == 0) {
                 common_log(LOG_INFO, "Unsubscribing from now-unused group feed $oprofile->feeduri");
                 $oprofile->unsubscribe();
             }
 
-
             $member = Profile::staticGet($user->id);
 
             $act = new Activity();