Skip to content

Commit

Permalink
change auth order
Browse files Browse the repository at this point in the history
  • Loading branch information
dholms committed Sep 14, 2023
1 parent 85fb95f commit c1cafd7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/pds/src/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,14 +120,14 @@ export class ServerAuth {
return { status: Missing, admin: false, moderator: false, triage: false }
}
const { username, password } = parsed
if (username === 'admin' && password === this._triagePass) {
return { status: Valid, admin: false, moderator: false, triage: true }
if (username === 'admin' && password === this._adminPass) {
return { status: Valid, admin: true, moderator: true, triage: true }
}
if (username === 'admin' && password === this._moderatorPass) {
return { status: Valid, admin: false, moderator: true, triage: true }
}
if (username === 'admin' && password === this._adminPass) {
return { status: Valid, admin: true, moderator: true, triage: true }
if (username === 'admin' && password === this._triagePass) {
return { status: Valid, admin: false, moderator: false, triage: true }
}
return { status: Invalid, admin: false, moderator: false, triage: false }
}
Expand Down

0 comments on commit c1cafd7

Please sign in to comment.