Skip to content

Commit

Permalink
refactor: Remove unused catch variables
Browse files Browse the repository at this point in the history
Jiralite committed Jan 16, 2025
1 parent 2f549e8 commit cfb9247
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions guide/message-components/interactions.md
Original file line number Diff line number Diff line change
@@ -47,7 +47,7 @@ const collectorFilter = i => i.user.id === interaction.user.id;

try {
const confirmation = await response.resource.message.awaitMessageComponent({ filter: collectorFilter, time: 60_000 });
} catch (e) {
} catch {
await interaction.editReply({ content: 'Confirmation not received within 1 minute, cancelling', components: [] });
}
```
@@ -75,7 +75,7 @@ try {
} else if (confirmation.customId === 'cancel') {
await confirmation.update({ content: 'Action cancelled', components: [] });
}
} catch (e) {
} catch {
await interaction.editReply({ content: 'Confirmation not received within 1 minute, cancelling', components: [] });
}
```
2 changes: 1 addition & 1 deletion guide/voice/voice-connections.md
Original file line number Diff line number Diff line change
@@ -111,7 +111,7 @@ connection.on(VoiceConnectionStatus.Disconnected, async (oldState, newState) =>
entersState(connection, VoiceConnectionStatus.Connecting, 5_000),
]);
// Seems to be reconnecting to a new channel - ignore disconnect
} catch (error) {
} catch {
// Seems to be a real disconnect which SHOULDN'T be recovered from
connection.destroy();
}

0 comments on commit cfb9247

Please sign in to comment.