1
0
Fork 0
mirror of synced 2024-10-05 20:53:27 +13:00

feat: public scope for api key

This commit is contained in:
loks0n 2023-10-26 15:07:51 +01:00
parent 49425fb8fc
commit 2743ac6934

View file

@ -495,7 +495,7 @@ App::init()
]);
$role = Auth::USER_ROLE_APPS;
$scopes = \array_merge($roles[$role]['scopes'], $key->getAttribute('scopes', []));
$scopes = \array_merge($roles[$role]['scopes'], $key->getAttribute('scopes', []), ['public']);
$expire = $key->getAttribute('expire');
if (!empty($expire) && $expire < DateTime::formatTz(DateTime::now())) {