aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2012-05-25 17:42:35 -0700
committerfriendica <info@friendica.com>2012-05-25 17:42:35 -0700
commit0ef8ccf11bbc6f353610b0a67c203a7f8438387b (patch)
tree5a0a2f313072848bba49f812d1ae56ce2ac3c03e
parent27c903a8d0d9e8eeca31a21356256593da683da6 (diff)
downloadvolse-hubzilla-0ef8ccf11bbc6f353610b0a67c203a7f8438387b.tar.gz
volse-hubzilla-0ef8ccf11bbc6f353610b0a67c203a7f8438387b.tar.bz2
volse-hubzilla-0ef8ccf11bbc6f353610b0a67c203a7f8438387b.zip
fix wall_uploaded photo permissions on group post by member
-rw-r--r--mod/item.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/mod/item.php b/mod/item.php
index 81dd553cd..df242d6f7 100644
--- a/mod/item.php
+++ b/mod/item.php
@@ -355,13 +355,15 @@ function item_post(&$a) {
$image_uri = substr($image_uri,0, strpos($image_uri,'-'));
if(! strlen($image_uri))
continue;
- $srch = '<' . intval($contact_record['id']) . '>';
+ $srch = '<' . intval($contact_id) . '>';
+
$r = q("SELECT `id` FROM `photo` WHERE `allow_cid` = '%s' AND `allow_gid` = '' AND `deny_cid` = '' AND `deny_gid` = ''
AND `resource-id` = '%s' AND `uid` = %d LIMIT 1",
dbesc($srch),
dbesc($image_uri),
intval($profile_uid)
);
+
if(! count($r))
continue;