Skip to content

Commit

Permalink
fix: 馃毃 being able to close tickets from other servers (closes #466)
Browse files Browse the repository at this point in the history
  • Loading branch information
eartharoid committed Jul 30, 2023
1 parent 32697c6 commit c6c1aac
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/commands/slash/force-close.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ module.exports = class ForceCloseSlashCommand extends SlashCommand {
const tickets = await client.prisma.ticket.findMany({
where: {
categoryId: categoryId ?? undefined, // must be undefined not null
guildId: interaction.guild.id,
lastMessageAt: { lte: new Date(Date.now() - time) },
open: true,
},
Expand Down

0 comments on commit c6c1aac

Please sign in to comment.