prevent triggering foreign key constraints in import

This commit is contained in:
Infinidoge 2025-01-01 12:22:11 -05:00
parent 0093c92a7e
commit 7f70c2afc8
Signed by: Infinidoge
SSH key fingerprint: SHA256:GT2StvPQMMfFHyiiFJymQxfTG/z6EWLJ6NWItf5K5sA

View file

@ -121,6 +121,8 @@ You may want to `{ctx.clean_prefix}nomen export` first"""
}
notifications = self.bot.get_cog("Notifications")
await ctx.bot.db.execute("INSERT OR IGNORE INTO users (user_id) VALUES(?)", (ctx.author.id,))
await ctx.bot.db.commit()
try:
await self.import_json(ctx, data)