Fix token creation in php 8.1

This commit is contained in:
lalka2018 2023-10-28 15:47:46 +03:00
parent f57a470c5d
commit 3f1c9cd5ff

View file

@ -48,7 +48,7 @@ class APIToken extends RowModel
$this->delete();
}
function save(): void
function save(?bool $log = false): void
{
if(is_null($this->getRecord()))
$this->stateChanges("secret", bin2hex(openssl_random_pseudo_bytes(36)));