allow the photo_rand widget to access photos from any channel (useful if the widget is used in sys-generated pages). You still need permission.
This commit is contained in:
parent
03a457ed83
commit
f17ef6aa90
@ -828,7 +828,11 @@ function widget_photo_rand($arr) {
|
|||||||
else
|
else
|
||||||
$album = '';
|
$album = '';
|
||||||
|
|
||||||
$channel_id = get_app()->profile_uid;
|
$channel_id = 0;
|
||||||
|
if(array_key_exists('channel_id',$arr) && intval($arr['channel_id']))
|
||||||
|
$channel_id = intval($arr['channel_id']);
|
||||||
|
if(! $channel_id)
|
||||||
|
$channel_id = get_app()->profile_uid;
|
||||||
if(! $channel_id)
|
if(! $channel_id)
|
||||||
return '';
|
return '';
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user