]> git.mxchange.org Git - friendica.git/commitdiff
fix typo, check for empty group in network page
authorFriendika <info@friendika.com>
Mon, 3 Jan 2011 21:53:26 +0000 (13:53 -0800)
committerFriendika <info@friendika.com>
Mon, 3 Jan 2011 21:53:26 +0000 (13:53 -0800)
mod/contacts.php
mod/display.php
mod/network.php
mod/profile.php

index 320c0f4201c9e4b4c2ce759219dffaaffcc31e9d..92bce0a73fef4f9b4577c4c9391dfa0557cc620d 100644 (file)
@@ -166,7 +166,7 @@ function contacts_content(&$a) {
                                        '$content' => t('stopped following'),
                                        '$nick' => $a->user['nickname'],
                                        '$verb' => ACTIVITY_UNFOLLOW,
-                                       '$ostat_follow' => '<as:verb>http://ostatus.org/schema/1.0/unfollow</as:verb>' . "\r\n";
+                                       '$ostat_follow' => '<as:verb>http://ostatus.org/schema/1.0/unfollow</as:verb>' . "\r\n"
                                ));
 
                                if((x($orig_record[0],'notify')) && (strlen($orig_record[0]['notify']))) {
index 30b55deceada0e7b07bc29f9631f29db3fbbfd54..cad60d2754ce5990f7040463633c1b8a3e7a8d64 100644 (file)
@@ -243,7 +243,7 @@ function display_content(&$a) {
 
                        $tmp_item = replace_macros($template,array(
                                '$id' => $item['item_id'],
-                               '$title' => t('View $name's profile'),
+                               '$title' => t('View $name\'s profile'),
                                '$profile_url' => $profile_link,
                                '$name' => $profile_name,
                                '$sparkle' => $sparkle,
index e1bec8dfa68c638a210ef1e5bf4b7798afbd9d1a..08607fa18e8d5baf02faa543f3365bf362c3705e 100644 (file)
@@ -104,10 +104,15 @@ function network_content(&$a, $update = 0) {
                }
 
                $contacts = expand_groups(array($group));
-               $contact_str = implode(',',$contacts);
-                $sql_extra = " AND `item`.`parent` IN ( SELECT `parent` FROM `item` WHERE `id` = `parent` AND `contact-id` IN ( $contact_str )) ";
-                $o = '<h4>' . t('Group: ') . $r[0]['name'] . '</h4>' . $o;
-
+               if((is_array($contacts)) && count($contacts)) {
+                       $contact_str = implode(',',$contacts);
+               }
+               else {
+                               $contact_str = ' 0 ';
+                               notice( t('Group is empty'));
+               }
+               $sql_extra = " AND `item`.`parent` IN ( SELECT `parent` FROM `item` WHERE `id` = `parent` AND `contact-id` IN ( $contact_str )) ";
+               $o = '<h4>' . t('Group: ') . $r[0]['name'] . '</h4>' . $o;
        }
 
        $r = q("SELECT COUNT(*) AS `total`
@@ -286,7 +291,7 @@ function network_content(&$a, $update = 0) {
 
                        $tmp_item = replace_macros($template,array(
                                '$id' => $item['item_id'],
-                               '$title' => t('View $name's profile'),
+                               '$title' => t('View $name\'s profile'),
                                '$profile_url' => $profile_link,
                                '$name' => $profile_name,
                                '$thumb' => $profile_avatar,
index 7a57bd5a42a4ad16b85deedffd171db51ac30297..5479f28068f9971ec65548327d1118c44cc883da 100644 (file)
@@ -344,7 +344,7 @@ function profile_content(&$a, $update = 0) {
 
                        $tmp_item = replace_macros($template,array(
                                '$id' => $item['item_id'],
-                               '$title' => t('View $name's profile'),
+                               '$title' => t('View $name\'s profile'),
                                '$profile_url' => $profile_link,
                                '$name' => $profile_name,
                                '$thumb' => $profile_avatar,