set isnomadic before accessing

This commit is contained in:
Mike Macgirvin 2024-07-20 08:30:57 +10:00
parent 3615a857d8
commit 967a0aa92d

View file

@ -300,8 +300,9 @@ class Item extends Controller
if (!$chan) {
http_status_exit(404, 'Not found');
}
$this->isNomadic = PConfig::Get($chan['channel_id'], 'system', 'nomadicAP');
if (!perm_is_allowed($chan['channel_id'], get_observer_hash(), 'view_stream')) {
http_status_exit(403, 'Forbidden');
}
@ -756,6 +757,8 @@ class Item extends Controller
killme();
}
$this->isNomadic = PConfig::Get($channel['channel_id'], 'system', 'nomadicAP');
$owner_xchan = null;
$r = q(