Fix crash due to remaining raise() in getDepends()

This commit is contained in:
rubenwardy 2018-05-27 23:02:11 +01:00
parent d046de8057
commit d0969263ba
No known key found for this signature in database
GPG Key ID: A1E29D52FF81513C
1 changed files with 41 additions and 43 deletions

View File

@ -299,10 +299,12 @@ def getDepends(package):
if url.netloc == "github.com":
urlmaker = GithubURLMaker(url)
else:
raise TaskError("Unsupported repo")
return {}
result = {}
if urlmaker.isValid():
if not urlmaker.isValid():
return {}
#
# Try getting depends on mod.conf
#
@ -346,10 +348,6 @@ def getDepends(package):
return result
else:
print(TaskError("non-github depends detector not implemented yet!"))
return {}
def importDependencies(package, mpackage_cache):
if Dependency.query.filter_by(depender=package).count() != 0: