Merge pull request #24040 from rallytime/bp-24027

Backport #24027 to 2015.5
This commit is contained in:
Justin Findlay 2015-05-21 17:43:54 -06:00
commit 82de059891

View File

@ -328,7 +328,7 @@ def mod_repo(repo, **kwargs):
repo or alias
alias by which the zypper refers to the repo
url or mirrorlist
url, mirrorlist or baseurl
the URL for zypper to reference
enabled
@ -361,7 +361,7 @@ def mod_repo(repo, **kwargs):
# An attempt to add new one?
if repo not in repos_cfg.sections():
url = kwargs.get('url', kwargs.get('mirrorlist'))
url = kwargs.get('url', kwargs.get('mirrorlist', kwargs.get('baseurl')))
if not url:
raise CommandExecutionError(
'Repository \'{0}\' not found and no URL passed to create one.'.format(repo))