use Friendica\App;
use Friendica\Core\L10n;
use Friendica\Core\System;
-use Friendica\Database\dba;
+use Friendica\Database\DBA;
use Friendica\Database\DBM;
use Friendica\Model\Contact;
use Friendica\Model\Profile;
if (!empty($cid)) {
$fields = ['id', 'uid', 'nurl', 'url', 'addr', 'name', 'network', 'poll', 'issued-id', 'dfrn-id', 'duplex'];
- $contact = dba::selectFirst('contact', $fields, ['id' => $cid, 'uid' => [0, local_user()]]);
+ $contact = DBA::selectFirst('contact', $fields, ['id' => $cid, 'uid' => [0, local_user()]]);
if (!DBM::is_result($contact)) {
notice(L10n::t('Contact not found.'));
goaway(System::baseUrl());
if ($contact['uid'] == 0 && local_user()) {
// Let's have a look if there is an established connection
// between the puplic contact we have found and the local user.
- $contact = dba::selectFirst('contact', $fields, ['nurl' => $contact['nurl'], 'uid' => local_user()]);
+ $contact = DBA::selectFirst('contact', $fields, ['nurl' => $contact['nurl'], 'uid' => local_user()]);
if (DBM::is_result($contact)) {
$cid = $contact['id'];
$fields = ['uid' => local_user(), 'cid' => $cid, 'dfrn_id' => $dfrn_id,
'sec' => $sec, 'expire' => time() + 45];
- dba::insert('profile_check', $fields);
+ DBA::insert('profile_check', $fields);
logger('mod_redir: ' . $contact['name'] . ' ' . $sec, LOGGER_DEBUG);