*/
use Friendica\Core\Config;
-use Friendica\Database\Dbm;
+use Friendica\Database\DBM;
use Memcache;
use dba;
dba::lock('locks');
$lock = dba::select('locks', array('locked', 'pid'), array('name' => $fn_name), array('limit' => 1));
- if (Dbm::is_result($lock)) {
+ if (DBM::is_result($lock)) {
if ($lock['locked']) {
// When the process id isn't used anymore, we can safely claim the lock for us.
if (!posix_kill($lock['pid'], 0)) {
dba::update('locks', array('locked' => true, 'pid' => getmypid()), array('name' => $fn_name));
$got_lock = true;
}
- } elseif (!Dbm::is_result($lock)) {
+ } elseif (!DBM::is_result($lock)) {
dba::insert('locks', array('name' => $fn_name, 'locked' => true, 'pid' => getmypid()));
$got_lock = true;
}