aboutsummaryrefslogtreecommitdiff
path: root/lib/models/resources/GlobalResourceLock.class.php
diff options
context:
space:
mode:
authorJan-Hendrik Willms <tleilax+github@gmail.com>2023-05-08 17:08:52 +0200
committerJan-Hendrik Willms <tleilax+github@gmail.com>2023-05-08 17:08:52 +0200
commita1fda2758e9c241ac3eb980ac8716dfedbe9dd3c (patch)
tree2190f0478fb153efdb8ba48ebb574c7691f4f351 /lib/models/resources/GlobalResourceLock.class.php
parent244d00ed91ad2b4b83e902a45cd6def3d7bc7e86 (diff)
let phpcsfixer fix errors according to @PSR12 rules on lib/modelsphpcsfixer
Diffstat (limited to 'lib/models/resources/GlobalResourceLock.class.php')
-rw-r--r--lib/models/resources/GlobalResourceLock.class.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/models/resources/GlobalResourceLock.class.php b/lib/models/resources/GlobalResourceLock.class.php
index 541cc0f..8b0d01b 100644
--- a/lib/models/resources/GlobalResourceLock.class.php
+++ b/lib/models/resources/GlobalResourceLock.class.php
@@ -28,13 +28,13 @@
class GlobalResourceLock extends SimpleORMap
{
protected static $defined_types = [];
-
+
public function __construct($id = null)
{
self::initDefinedTypes();
parent::__construct($id);
}
-
+
protected static function initDefinedTypes()
{
if (empty(self::$defined_types)) {
@@ -45,14 +45,14 @@ class GlobalResourceLock extends SimpleORMap
];
}
}
-
+
protected static function configure($config = [])
{
$config['db_table'] = 'global_resource_locks';
-
+
parent::configure($config);
}
-
+
public static function isLocked($begin, $end)
{
return self::countBySql('begin < :end AND end > :begin', compact('begin', 'end')) > 0;
@@ -68,7 +68,7 @@ class GlobalResourceLock extends SimpleORMap
self::initDefinedTypes();
return self::$defined_types;
}
-
+
/**
* Returns a string representation of the type of this resource lock.
*