Skip to content
Extraits de code Groupes Projets
Non vérifiée Valider 674b213f rédigé par Sorunome's avatar Sorunome
Parcourir les fichiers

fix unpuppeting by fixing delete_user_token

parent 1c29bbfe
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -175,14 +175,22 @@ export class DiscordStore { ...@@ -175,14 +175,22 @@ export class DiscordStore {
public async delete_user_token(discordId: string): Promise<void> { public async delete_user_token(discordId: string): Promise<void> {
log.silly("SQL", "delete_user_token => ", discordId); log.silly("SQL", "delete_user_token => ", discordId);
try { try {
await this.db.Run( await Promise.all([
this.db.Run(
` `
DELETE FROM user_id_discord_id WHERE discord_id = $id; DELETE FROM user_id_discord_id WHERE discord_id = $id;
`
, {
$id: discordId,
}),
this.db.Run(
`
DELETE FROM discord_id_token WHERE discord_id = $id; DELETE FROM discord_id_token WHERE discord_id = $id;
` `
, { , {
$id: discordId, $id: discordId,
}); }),
]);
} catch (err) { } catch (err) {
log.error("Error deleting user token ", err); log.error("Error deleting user token ", err);
throw err; throw err;
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter