mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 01:25:21 +02:00
Review updates
Update function name, descriptive variable names.
This commit is contained in:
parent
41159cd14f
commit
430bd7c6ac
8 changed files with 29 additions and 25 deletions
|
@ -36,19 +36,19 @@ function common_content(App $a)
|
|||
}
|
||||
|
||||
if ($cmd === 'loc' && $cid) {
|
||||
$c = dba::selectFirst('contact', ['name', 'url', 'photo'], ['id' => $cid, 'uid' => $uid]);
|
||||
$contact = dba::selectFirst('contact', ['name', 'url', 'photo'], ['id' => $cid, 'uid' => $uid]);
|
||||
|
||||
if (DBM::is_result($c)) {
|
||||
if (DBM::is_result($contact)) {
|
||||
$a->page['aside'] = "";
|
||||
Profile::load($a, "", 0, Contact::getDetailsByURL($c["url"]));
|
||||
Profile::load($a, "", 0, Contact::getDetailsByURL($contact["url"]));
|
||||
}
|
||||
} else {
|
||||
$c = dba::selectFirst('contact', ['name', 'url', 'photo'], ['self' => true, 'uid' => $uid]);
|
||||
$contact = dba::selectFirst('contact', ['name', 'url', 'photo'], ['self' => true, 'uid' => $uid]);
|
||||
|
||||
if (DBM::is_result($c)) {
|
||||
if (DBM::is_result($contact)) {
|
||||
$vcard_widget = replace_macros(get_markup_template("vcard-widget.tpl"), array(
|
||||
'$name' => htmlentities($c['name']),
|
||||
'$photo' => $c['photo'],
|
||||
'$name' => htmlentities($contact['name']),
|
||||
'$photo' => $contact['photo'],
|
||||
'url' => 'contacts/' . $cid
|
||||
));
|
||||
|
||||
|
@ -59,7 +59,7 @@ function common_content(App $a)
|
|||
}
|
||||
}
|
||||
|
||||
if (!DBM::is_result($c)) {
|
||||
if (!DBM::is_result($contact)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue