Fix CommandSyncFailure raising for other 400 error types

This commit is contained in:
Rapptz 2022-09-06 02:37:16 -04:00
parent e8f6b29a2d
commit 5cc6af5917

View File

@ -1068,7 +1068,7 @@ class CommandTree(Generic[ClientT]):
else:
data = await self._http.bulk_upsert_guild_commands(self.client.application_id, guild.id, payload=payload)
except HTTPException as e:
if e.status == 400:
if e.status == 400 and e.code == 50035:
raise CommandSyncFailure(e, commands) from None
raise