# HG changeset patch # User Mads Kiilerich # Date 2013-01-03 17:25:40 # Node ID db4ca2212ec0dda0bf12e9bf01865bbbe2058e86 # Parent 1e7839c0930acdc20d42e4489c76dc187830df98 compare: more helpful error messages when a repo wasn't found diff --git a/rhodecode/controllers/compare.py b/rhodecode/controllers/compare.py --- a/rhodecode/controllers/compare.py +++ b/rhodecode/controllers/compare.py @@ -103,8 +103,11 @@ class CompareController(BaseRepoControll c.org_repo = org_repo = Repository.get_by_repo_name(org_repo) c.other_repo = other_repo = Repository.get_by_repo_name(other_repo) - if c.org_repo is None or c.other_repo is None: - log.error('Could not found repo %s or %s' % (org_repo, other_repo)) + if c.org_repo is None: + log.error('Could not find org repo %s' % org_repo) + raise HTTPNotFound + if c.other_repo is None: + log.error('Could not find other repo %s' % other_repo) raise HTTPNotFound if c.org_repo != c.other_repo and h.is_git(c.rhodecode_repo):