aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMilo Casagrande <milo.casagrande@linaro.org>2014-12-08 17:21:57 +0100
committerMilo Casagrande <milo.casagrande@linaro.org>2014-12-08 17:21:57 +0100
commitc6c3bf76bca1a8e18bd97c20ff514355d02ff7fe (patch)
tree9c8a0c1e82ab949adc6662990dac00b4768cfb5c
parentf956ccf5e27ea445e4ebabc89c96ef1a64380d9c (diff)
Return None instead of failing with 400.2014.12.1
Change-Id: I1e06c1772c15e0426f001e3365cfef840c511375
-rw-r--r--app/dashboard/utils/backend.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/app/dashboard/utils/backend.py b/app/dashboard/utils/backend.py
index c56d4c3..2a7f85f 100644
--- a/app/dashboard/utils/backend.py
+++ b/app/dashboard/utils/backend.py
@@ -42,8 +42,8 @@ def translate_git_url(git_url, commit_id):
:return The base URL to create URLs, and the real commit URL.
"""
- base_url = ""
- commit_url = ""
+ base_url = None
+ commit_url = None
if git_url and commit_id:
t_url = urlparse.urlparse(git_url)
@@ -65,8 +65,6 @@ def translate_git_url(git_url, commit_id):
(known_git[2] % path) + commit_id,
"", "", ""
))
- else:
- abort(400)
return base_url, commit_url