do not overwrite $sql_extra

(cherry picked from commit 4706ff6938)
This commit is contained in:
Mario Vavti 2019-02-03 13:52:50 +00:00 committed by Mario
parent ddbc35181c
commit cda8a7be38

View File

@ -181,7 +181,7 @@ class Oep extends \Zotlabs\Web\Controller {
dbesc($res)
);
if($r) {
$sql_extra = "and item.id = " . intval($r[0]['iid']) . " ";
$sql_extra .= " and item.id = " . intval($r[0]['iid']) . " ";
}
else {
return $ret;
@ -255,6 +255,8 @@ class Oep extends \Zotlabs\Web\Controller {
if(! $channel)
return $ret;
hz_syslog($nick);
if(! perm_is_allowed($channel['channel_id'],get_observer_hash(),'view_pages'))
return $ret;
@ -265,7 +267,7 @@ class Oep extends \Zotlabs\Web\Controller {
dbesc($res)
);
if($r) {
$sql_extra = "and item.id = " . intval($r[0]['iid']) . " ";
$sql_extra .= " and item.id = " . intval($r[0]['iid']) . " ";
}
else {
return $ret;