mirror of
https://github.com/friendica/friendica
synced 2025-04-28 15:04:26 +02:00
Rename DBM method calls to DBA method calls
This commit is contained in:
parent
8ddb94ef06
commit
0ec44f3e8a
153 changed files with 813 additions and 918 deletions
|
@ -7,7 +7,6 @@ namespace Friendica\Model;
|
|||
use Friendica\BaseObject;
|
||||
use Friendica\Core\L10n;
|
||||
use Friendica\Database\DBA;
|
||||
use Friendica\Database\DBM;
|
||||
|
||||
require_once 'boot.php';
|
||||
require_once 'include/dba.php';
|
||||
|
@ -39,7 +38,7 @@ class Group extends BaseObject
|
|||
// access lists. What we're doing here is reviving the dead group, but old content which
|
||||
// was restricted to this group may now be seen by the new group members.
|
||||
$group = DBA::selectFirst('group', ['deleted'], ['id' => $gid]);
|
||||
if (DBM::is_result($group) && $group['deleted']) {
|
||||
if (DBA::is_result($group) && $group['deleted']) {
|
||||
DBA::update('group', ['deleted' => 0], ['id' => $gid]);
|
||||
notice(L10n::t('A deleted group with this name was revived. Existing item permissions <strong>may</strong> apply to this group and any future members. If this is not what you intended, please create another group with a different name.') . EOL);
|
||||
}
|
||||
|
@ -133,7 +132,7 @@ class Group extends BaseObject
|
|||
}
|
||||
|
||||
$group = DBA::selectFirst('group', ['id'], ['uid' => $uid, 'name' => $name]);
|
||||
if (DBM::is_result($group)) {
|
||||
if (DBA::is_result($group)) {
|
||||
return $group['id'];
|
||||
}
|
||||
|
||||
|
@ -152,13 +151,13 @@ class Group extends BaseObject
|
|||
}
|
||||
|
||||
$group = DBA::selectFirst('group', ['uid'], ['id' => $gid]);
|
||||
if (!DBM::is_result($group)) {
|
||||
if (!DBA::is_result($group)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// remove group from default posting lists
|
||||
$user = DBA::selectFirst('user', ['def_gid', 'allow_gid', 'deny_gid'], ['uid' => $group['uid']]);
|
||||
if (DBM::is_result($user)) {
|
||||
if (DBA::is_result($user)) {
|
||||
$change = false;
|
||||
|
||||
if ($user['def_gid'] == $gid) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue