aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar ToxicKidz <[email protected]>2021-03-26 14:54:07 -0400
committerGravatar ToxicKidz <[email protected]>2021-03-26 14:54:07 -0400
commit877671523c18aad4bb5061a1a2379beb5c761e3c (patch)
treed4fe0c210d2a19daaaed122e3e02f98cdc29ffe4
parentMake requested changes (diff)
Make repository accept either user/reponame or user reponame
-rw-r--r--bot/exts/evergreen/githubinfo.py11
1 files changed, 8 insertions, 3 deletions
diff --git a/bot/exts/evergreen/githubinfo.py b/bot/exts/evergreen/githubinfo.py
index 1b64b0eb..c8a6b3f7 100644
--- a/bot/exts/evergreen/githubinfo.py
+++ b/bot/exts/evergreen/githubinfo.py
@@ -102,12 +102,17 @@ class GithubInfo(commands.Cog):
await ctx.send(embed=embed)
@github_group.command(name='repository', aliases=('repo',))
- async def github_repo_info(self, ctx: commands.Context, repo: str) -> None:
- """Fetches a repositories' GitHub information. The repository should look like `user/reponame`."""
+ async def github_repo_info(self, ctx: commands.Context, *repo: str) -> None:
+ """
+ Fetches a repositories' GitHub information.
+
+ The repository should look like `user/reponame` or `user reponame`.
+ """
+ repo = '/'.join(repo)
if repo.count('/') != 1:
embed = discord.Embed(
title=random.choice(NEGATIVE_REPLIES),
- description="The repository should look like `user/reponame`.",
+ description="The repository should look like `user/reponame` or `user reponame`.",
colour=Colours.soft_red
)