profile edit link missing in photo menu for non-dfrn contacts
This commit is contained in:
parent
438473529c
commit
d2b28206ce
31
boot.php
31
boot.php
|
@ -2701,27 +2701,24 @@ function item_photo_menu($item){
|
||||||
// Then check if we can use a sparkle (redirect) link to the profile by virtue of it being our contact
|
// Then check if we can use a sparkle (redirect) link to the profile by virtue of it being our contact
|
||||||
// or a friend's contact that we both have a connection to.
|
// or a friend's contact that we both have a connection to.
|
||||||
|
|
||||||
if(((local_user() && ($profile_owner == 0))
|
if((local_user() && ($profile_owner == 0))
|
||||||
|| ($profile_owner && $profile_owner == local_user()))
|
|| ($profile_owner && $profile_owner == local_user())) {
|
||||||
&& strlen($item['author-link'])) {
|
|
||||||
|
|
||||||
if(link_compare($item['author-link'],$item['url']) && ($item['network'] === 'dfrn') && (! $item['self'])) {
|
if(strlen($item['author-link']) && link_compare($item['author-link'],$item['url']))
|
||||||
$status_link = $redirect_url."?url=status";
|
$redir = $redirect_url;
|
||||||
$profile_link = $redirect_url."?url=profile";
|
|
||||||
$photos_link = $redirect_url."?url=photos";
|
|
||||||
$pm_url = $a->get_baseurl() . '/message/new/' . $item['cid'];
|
|
||||||
$contact_url = $item['self']?"":$a->get_baseurl() . '/contacts/' . $item['cid'];
|
|
||||||
}
|
|
||||||
elseif(isset($a->authors[$item['author-link']])) {
|
elseif(isset($a->authors[$item['author-link']])) {
|
||||||
$redirect_url = $a->get_baseurl() . '/redir/' . $a->authors[$item['author-link']]['id'];
|
$redir = $a->get_baseurl() . '/redir/' . $a->authors[$item['author-link']]['id'];
|
||||||
$status_link = $redirect_url."?url=status";
|
$cid = $a->authors[$item['author-link']]['id'];
|
||||||
$profile_link = $redirect_url."?url=profile";
|
|
||||||
$photos_link = $redirect_url."?url=photos";
|
|
||||||
if ($a->authors[$item['author-link']]['network']==='dfrn'){
|
|
||||||
$pm_url = $a->get_baseurl() . '/message/new/' . $a->authors[$item['author-link']]['id'];
|
|
||||||
}
|
}
|
||||||
$contact_url = $item['self']?"":$a->get_baseurl() . '/contacts/' . $a->authors[$item['author-link']]['id'] ;
|
|
||||||
|
if($item['network'] === 'dfrn' && (! $item['self'])) {
|
||||||
|
$status_link = $redir . "?url=status";
|
||||||
|
$profile_link = $redir . "?url=profile";
|
||||||
|
$photos_link = $redir . "?url=photos";
|
||||||
|
$pm_url = $a->get_baseurl() . '/message/new/' . $cid;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$contact_url = $item['self']?"":$a->get_baseurl() . '/contacts/' . (($item['cid']) ? $item['cid'] : $cid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue