fix including suspended users in getter
All checks were successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/lint-sw Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
All checks were successful
ci/woodpecker/push/build Pipeline was successful
ci/woodpecker/push/lint-backend Pipeline was successful
ci/woodpecker/push/lint-foundkey-js Pipeline was successful
ci/woodpecker/push/lint-client Pipeline was successful
ci/woodpecker/push/lint-sw Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
This commit is contained in:
parent
9a085e9d42
commit
ba2b7ef43c
1 changed files with 3 additions and 3 deletions
|
@ -33,7 +33,7 @@ export async function getUser(userId: User['id'], includeSuspended = false) {
|
|||
const user = await Users.findOneBy({
|
||||
id: userId,
|
||||
isDeleted: false,
|
||||
isSuspended: !includeSuspended,
|
||||
...(includeSuspended ? {} : {isSuspended: false}),
|
||||
});
|
||||
|
||||
if (user == null) {
|
||||
|
@ -51,7 +51,7 @@ export async function getRemoteUser(userId: User['id'], includeSuspended = false
|
|||
id: userId,
|
||||
host: Not(IsNull()),
|
||||
isDeleted: false,
|
||||
isSuspended: !includedSuspended,
|
||||
...(includeSuspended ? {} : {isSuspended: false}),
|
||||
});
|
||||
|
||||
if (user == null) {
|
||||
|
@ -69,7 +69,7 @@ export async function getLocalUser(userId: User['id'], includeSuspended = false)
|
|||
id: userId,
|
||||
host: IsNull(),
|
||||
isDeleted: false,
|
||||
isSuspended: !includeSuspended,
|
||||
...(includeSuspended ? {} : {isSuspended: false}),
|
||||
});
|
||||
|
||||
if (user == null) {
|
||||
|
|
Loading…
Reference in a new issue