Refactor lock.php

This commit is contained in:
Zankaria
2024-02-16 14:47:20 +01:00
parent 00b05099f3
commit 760431606d
2 changed files with 74 additions and 33 deletions

View File

@@ -3,7 +3,7 @@
class Queue {
function __construct($key) { global $config;
if ($config['queue']['enabled'] == 'fs') {
$this->lock = new Lock($key);
$this->lock = Locks::get_lock($config, $key);
$key = str_replace('/', '::', $key);
$key = str_replace("\0", '', $key);
$this->key = "tmp/queue/$key/";