diff options
Diffstat (limited to 'modules-available/webinterface/inc/webinterface.inc.php')
-rw-r--r-- | modules-available/webinterface/inc/webinterface.inc.php | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/modules-available/webinterface/inc/webinterface.inc.php b/modules-available/webinterface/inc/webinterface.inc.php index 276110eb..20be6545 100644 --- a/modules-available/webinterface/inc/webinterface.inc.php +++ b/modules-available/webinterface/inc/webinterface.inc.php @@ -110,4 +110,17 @@ class WebInterface return $task['id'] ?? null; } + public static function getApiKey(): ?string + { + $key = Property::get(self::PROP_API_KEY, null); + if (empty($key)) + return null; + return $key; + } + + public static function setApiKey(?string $key): void + { + Property::set(self::PROP_API_KEY, empty($key) ? null : $key); + } + }
\ No newline at end of file |