diff --git a/token_bot/tracker.py b/token_bot/tracker.py index 2cfd39d..3018b3d 100644 --- a/token_bot/tracker.py +++ b/token_bot/tracker.py @@ -191,7 +191,15 @@ class Tracker(Extension): description="List all alerts you have signed up for" ) async def list_alerts(self, ctx: SlashContext): + if not await self._users.exists(ctx.user.id): + await ctx.send("You are not registered with any region\n" + "Please register with /register before adding alerts", + ephemeral=True) + return alerts = await self._users.list_alerts(ctx.user.id) + if len(alerts) == 0: + await ctx.send("You do not have any alerts registered", ephemeral=True) + return alerts_str = f"You have {len(alerts)} out of 25 maximum alerts registered" embeds = [Embed( title="List of TokenBot Tracker Alerts",