]> git.mxchange.org Git - friendica.git/commitdiff
translate attendance with localize_item()
authorrabuzarus <>
Thu, 8 Oct 2015 20:23:09 +0000 (22:23 +0200)
committerrabuzarus <>
Thu, 8 Oct 2015 20:23:09 +0000 (22:23 +0200)
include/conversation.php

index c4605cf5d112dc2abde53e87f6a8e823719e64e1..5bc6525b72b19acaeebb3630b8b4ea9b03dec142 100644 (file)
@@ -100,7 +100,11 @@ function localize_item(&$item){
                $item['body'] = item_redir_and_replace_images($extracted['body'], $extracted['images'], $item['contact-id']);
 
        $xmlhead="<"."?xml version='1.0' encoding='UTF-8' ?".">";
-       if (activity_match($item['verb'],ACTIVITY_LIKE) || activity_match($item['verb'],ACTIVITY_DISLIKE)){
+       if (activity_match($item['verb'],ACTIVITY_LIKE) 
+               || activity_match($item['verb'],ACTIVITY_DISLIKE) 
+               || activity_match($item['verb'],ACTIVITY_ATTEND) 
+               || activity_match($item['verb'],ACTIVITY_ATTENDNO) 
+               || activity_match($item['verb'],ACTIVITY_ATTENDMAYBE)){
 
                $r = q("SELECT * from `item`,`contact` WHERE
                                `item`.`contact-id`=`contact`.`id` AND `item`.`uri`='%s';",
@@ -139,6 +143,15 @@ function localize_item(&$item){
                elseif(activity_match($item['verb'],ACTIVITY_DISLIKE)) {
                        $bodyverb = t('%1$s doesn\'t like %2$s\'s %3$s');
                }
+               elseif(activity_match($item['verb'],ACTIVITY_ATTEND)) {
+                       $bodyverb = t('%1$s attends %2$s\'s %3$s');
+               }
+               elseif(activity_match($item['verb'],ACTIVITY_ATTENDNO)) {
+                       $bodyverb = t('%1$s doesn\'t attend %2$s\'s %3$s');
+               }
+               elseif(activity_match($item['verb'],ACTIVITY_ATTENDMAYBE)) {
+                       $bodyverb = t('%1$s attends maybe %2$s\'s %3$s');
+               }
                $item['body'] = sprintf($bodyverb, $author, $objauthor, $plink);
 
        }