return if user is banned in api response
All checks were successful
delpoy / build-and-deploy (push) Successful in 1m7s
All checks were successful
delpoy / build-and-deploy (push) Successful in 1m7s
This commit is contained in:
parent
58bc475aec
commit
9352083884
@ -20,7 +20,9 @@ export const GET = (async ({ url }) => {
|
|||||||
username: user.username,
|
username: user.username,
|
||||||
firstname: user.firstname,
|
firstname: user.firstname,
|
||||||
lastname: user.lastname,
|
lastname: user.lastname,
|
||||||
ban_until: strike ? strike.ban_until.getTime() / 1000 : null
|
banned:
|
||||||
|
new Date(new Date(Date.now()).toUTCString()) <
|
||||||
|
new Date((strike?.ban_until ?? new Date(0)).toUTCString())
|
||||||
}),
|
}),
|
||||||
{ status: 200 }
|
{ status: 200 }
|
||||||
);
|
);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user