mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-23 19:37:23 +08:00
[api] add notifications
This commit is contained in:
+3
-1
@@ -35,7 +35,9 @@ if (!empty($_REQUEST['authkey'])) {
|
||||
if (empty($decrypted)) {
|
||||
err('Invalid authkey');
|
||||
}
|
||||
$userInfo = \App\Models\User::query()->where('id', $uid)->first(['id', 'passkey']);
|
||||
$userInfo = \Nexus\Database\NexusDB::remember("announce_user_passkey_$uid", 600, function () use ($uid) {
|
||||
return \App\Models\User::query()->where('id', $uid)->first(['id', 'passkey']);
|
||||
});
|
||||
if (!$userInfo) {
|
||||
err('Invalid authkey');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user