Rename DBM method calls to DBA method calls

This commit is contained in:
Hypolite Petovan 2018-07-21 08:40:21 -04:00 committed by Hypolite Petovan
commit 0ec44f3e8a
153 changed files with 813 additions and 918 deletions

View file

@ -4,7 +4,6 @@ use Friendica\App;
use Friendica\Core\L10n;
use Friendica\Core\System;
use Friendica\Database\DBA;
use Friendica\Database\DBM;
use Friendica\Model\Contact;
use Friendica\Model\Profile;
@ -25,7 +24,7 @@ function redir_init(App $a) {
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()]]);
if (!DBM::is_result($contact)) {
if (!DBA::is_result($contact)) {
notice(L10n::t('Contact not found.'));
goaway(System::baseUrl());
}
@ -44,7 +43,7 @@ function redir_init(App $a) {
// between the puplic contact we have found and the local user.
$contact = DBA::selectFirst('contact', $fields, ['nurl' => $contact['nurl'], 'uid' => local_user()]);
if (DBM::is_result($contact)) {
if (DBA::is_result($contact)) {
$cid = $contact['id'];
}