Enforce name minimums on media feeds
This commit is contained in:
parent
3e3fb55e35
commit
6f837d9ad3
2 changed files with 2 additions and 2 deletions
|
@ -53,7 +53,7 @@ class RedditCog(Scale):
|
|||
@check(admin_or_permissions(Permissions.MANAGE_GUILD))
|
||||
async def _reddit_follow(self, ctx: InteractionContext, name: str, channel: GuildText) -> None:
|
||||
name = name.replace("r/", "")
|
||||
if len(name) > 20:
|
||||
if len(name) > 20 or len(name) < 3:
|
||||
await ctx.send("Invalid Subreddit name", ephemeral=True)
|
||||
return
|
||||
|
||||
|
|
|
@ -63,7 +63,7 @@ class TwitterCog(Scale):
|
|||
self, ctx: InteractionContext, handle: str, channel: GuildText, retweets: bool = True
|
||||
) -> None:
|
||||
handle = handle.lower()
|
||||
if len(handle) > 15:
|
||||
if len(handle) > 15 or len(handle) < 4:
|
||||
await ctx.send("Invalid Twitter handle", ephemeral=True)
|
||||
return
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue