cleanup empty locks
This commit is contained in:
parent
9729e67e3d
commit
06065189d7
|
@ -105,6 +105,7 @@ class DBLockingProvider extends AbstractLockingProvider {
|
||||||
[$path]
|
[$path]
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->markRelease($path, $type);
|
$this->markRelease($path, $type);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -133,4 +134,17 @@ class DBLockingProvider extends AbstractLockingProvider {
|
||||||
}
|
}
|
||||||
$this->markChange($path, $targetType);
|
$this->markChange($path, $targetType);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* cleanup empty locks
|
||||||
|
*/
|
||||||
|
public function cleanEmptyLocks() {
|
||||||
|
$this->connection->executeUpdate(
|
||||||
|
'DELETE FROM `*PREFIX*file_locks` WHERE `lock` = 0'
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function __destruct() {
|
||||||
|
$this->cleanEmptyLocks();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue