diff options
author | friendica <info@friendica.com> | 2013-09-18 04:06:44 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2013-09-18 04:06:44 -0700 |
commit | 9d49f2a47bda2d01b0d08327d12e44ce3d5afb43 (patch) | |
tree | 8e434f7c7c95942f48868c853926e6174a4cd2be | |
parent | b0a4f1b30ab9bf5de2182b475ab5639f63a8e53f (diff) | |
download | volse-hubzilla-9d49f2a47bda2d01b0d08327d12e44ce3d5afb43.tar.gz volse-hubzilla-9d49f2a47bda2d01b0d08327d12e44ce3d5afb43.tar.bz2 volse-hubzilla-9d49f2a47bda2d01b0d08327d12e44ce3d5afb43.zip |
make collections work again
-rw-r--r-- | mod/network.php | 13 | ||||
-rw-r--r-- | version.inc | 2 |
2 files changed, 10 insertions, 5 deletions
diff --git a/mod/network.php b/mod/network.php index 9b108aef8..0d5f57a39 100644 --- a/mod/network.php +++ b/mod/network.php @@ -432,16 +432,21 @@ function network_content(&$a, $update = 0, $load = false) { // NOTREACHED } - $contacts = expand_groups(array($arr['group'])); - if((is_array($contacts)) && count($contacts)) { - $contact_str = implode(',',$contacts); + $contact_str = ''; + $contacts = group_get_members($group); + if($contacts) { + foreach($contacts as $c) { + if($contact_str) + $contact_str .= ','; + $contact_str .= "'" . $c['xchan'] . "'"; + } } else { $contact_str = ' 0 '; info( t('Group is empty')); } - $sql_extra = " AND item.parent IN ( SELECT DISTINCT parent FROM item WHERE true $sql_options AND ( author_xchan IN ( $contact_str ) OR owner_xchan in ( $contact_str) or allow_gid like '" . protect_sprintf('%<' . dbesc($r[0]['hash']) . '>%') . "' ) and item_restrict = 0 ) "; + $sql_extra = " AND item.parent IN ( SELECT DISTINCT parent FROM item WHERE true $sql_options AND (( author_xchan IN ( $contact_str ) OR owner_xchan in ( $contact_str)) or allow_gid like '" . protect_sprintf('%<' . dbesc($r[0]['hash']) . '>%') . "' ) and item_restrict = 0 ) "; } diff --git a/version.inc b/version.inc index 44ebbfe27..b1c3d8c72 100644 --- a/version.inc +++ b/version.inc @@ -1 +1 @@ -2013-09-17.439 +2013-09-18.440 |