Only show foreign items if the profile of the user isn't hidden. Show the user's theme - not the theme of the viewed profile.

This commit is contained in:
Michael Vogel 2014-08-28 01:06:41 +02:00
parent 4ad2bbddc7
commit 4bdd905b3e
4 changed files with 31 additions and 25 deletions

View File

@ -1414,7 +1414,9 @@ if(! function_exists('profile_load')) {
$a->page['title'] = $a->profile['name'] . " @ " . $a->config['sitename'];
if (!$profiledata)
$_SESSION['theme'] = $a->profile['theme'];
$_SESSION['mobile-theme'] = $a->profile['mobile-theme'];
/**

View File

@ -33,7 +33,7 @@ function display_init(&$a) {
WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0
AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = ''
AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = ''
AND `item`.`private` = 0
AND `item`.`private` = 0 AND NOT `user`.`hidewall`
AND `item`.`guid` = '%s'", $a->argv[1]);
// AND `item`.`private` = 0 AND `item`.`wall` = 1
if (count($r)) {
@ -65,6 +65,10 @@ function display_init(&$a) {
} else
$profiledata = array();
}
} else {
$a->error = 404;
notice( t('Item not found.') . EOL);
return;
}
}
@ -220,7 +224,7 @@ function display_content(&$a, $update = 0) {
WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0
AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = ''
AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = ''
AND `item`.`private` = 0
AND `item`.`private` = 0 AND NOT `user`.`hidewall`
AND `item`.`guid` = '%s'", $a->argv[1]);
// AND `item`.`private` = 0 AND `item`.`wall` = 1
if (count($r)) {