[V3] Disregard limitations on repo names (#1349)

This commit is contained in:
Will 2018-02-26 01:21:13 -05:00 committed by palmtree5
parent 09ddfe4250
commit 1363bc3f43
3 changed files with 2 additions and 8 deletions

View File

@ -4,11 +4,6 @@ from .repo_manager import RepoManager
from .installable import Installable from .installable import Installable
class RepoName(commands.Converter):
async def convert(self, ctx: commands.Context, arg: str) -> str:
return RepoManager.validate_and_normalize_repo_name(arg)
class InstalledCog(commands.Converter): class InstalledCog(commands.Converter):
async def convert(self, ctx: commands.Context, arg: str) -> Installable: async def convert(self, ctx: commands.Context, arg: str) -> Installable:
downloader = ctx.bot.get_cog("Downloader") downloader = ctx.bot.get_cog("Downloader")

View File

@ -14,7 +14,7 @@ from discord.ext import commands
from redbot.core.bot import Red from redbot.core.bot import Red
from .checks import install_agreement from .checks import install_agreement
from .converters import RepoName, InstalledCog from .converters import InstalledCog
from .errors import CloningError, ExistingGitRepo from .errors import CloningError, ExistingGitRepo
from .installable import Installable from .installable import Installable
from .log import log from .log import log
@ -197,7 +197,7 @@ class Downloader:
@repo.command(name="add") @repo.command(name="add")
@install_agreement() @install_agreement()
async def _repo_add(self, ctx, name: RepoName, repo_url: str, branch: str=None): async def _repo_add(self, ctx, name: str, repo_url: str, branch: str=None):
""" """
Add a new repo to Downloader. Add a new repo to Downloader.

View File

@ -554,7 +554,6 @@ class RepoManager:
New Repo object representing the cloned repository. New Repo object representing the cloned repository.
""" """
name = self.validate_and_normalize_repo_name(name)
if self.does_repo_exist(name): if self.does_repo_exist(name):
raise InvalidRepoName( raise InvalidRepoName(
"That repo name you provided already exists." "That repo name you provided already exists."