Improve dba::selectFirst calls
- Fix remaining $r[0] references - Rename $r to meaningful names
This commit is contained in:
@@ -94,9 +94,9 @@ function nav_info(App $a)
|
||||
$nav['usermenu'][] = array('notes/', t('Personal notes'), '', t('Your personal notes'));
|
||||
|
||||
// user info
|
||||
$r = dba::selectFirst('contact', ['micro'], ['uid' => $a->user['uid'], 'self' => true]);
|
||||
$contact = dba::selectFirst('contact', ['micro'], ['uid' => $a->user['uid'], 'self' => true]);
|
||||
$userinfo = array(
|
||||
'icon' => (DBM::is_result($r) ? $a->remove_baseurl($r['micro']) : 'images/person-48.jpg'),
|
||||
'icon' => (DBM::is_result($contact) ? $a->remove_baseurl($contact['micro']) : 'images/person-48.jpg'),
|
||||
'name' => $a->user['username'],
|
||||
);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user