Skip to content

Commit

Permalink
fix(db): use unqualified table name
Browse files Browse the repository at this point in the history
  • Loading branch information
BastiDood committed Aug 3, 2024
1 parent d4df9d4 commit e232175
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion database/src/database.ts
Original file line number Diff line number Diff line change
Expand Up @@ -456,7 +456,7 @@ export class Database implements Loggable {
@timed async getDesignatedSenderCredentials() {
const sql = this.#sql;
const [first, ...rest] =
await sql`SELECT email, given_name, family_name, access_token, refresh_token, expiration FROM drap.designated_sender JOIN drap.candidate_senders USING (email) JOIN drap.users (email) WHERE user_id IS NOT NULL AND is_admin AND lab_id IS NULL FOR UPDATE OF drap.candidate_senders`;
await sql`SELECT email, given_name, family_name, access_token, refresh_token, expiration FROM drap.designated_sender JOIN drap.candidate_senders USING (email) JOIN drap.users USING (email) WHERE user_id IS NOT NULL AND is_admin AND lab_id IS NULL FOR UPDATE OF candidate_senders`;
strictEqual(rest.length, 0);
return typeof first === 'undefined' ? null : parse(DesignatedSenderCredentials, first);
}
Expand Down

0 comments on commit e232175

Please sign in to comment.