mirror of
https://github.com/friendica/friendica
synced 2025-05-03 21:04:09 +02:00
Improve dba::selectFirst calls
- Fix remaining $r[0] references - Rename $r to meaningful names
This commit is contained in:
parent
465e1d6a5c
commit
5fc4927764
29 changed files with 228 additions and 250 deletions
|
@ -63,11 +63,10 @@ class FKOAuth1 extends OAuthServer
|
|||
$a->timezone = $a->user['timezone'];
|
||||
}
|
||||
|
||||
$r = dba::selectFirst('contact', [], ['uid' => $_SESSION['uid'], 'self' => 1]);
|
||||
|
||||
if (DBM::is_result($r)) {
|
||||
$a->contact = $r;
|
||||
$a->cid = $r['id'];
|
||||
$contact = dba::selectFirst('contact', [], ['uid' => $_SESSION['uid'], 'self' => 1]);
|
||||
if (DBM::is_result($contact)) {
|
||||
$a->contact = $contact;
|
||||
$a->cid = $contact['id'];
|
||||
$_SESSION['cid'] = $a->cid;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue