# HG changeset patch # User Mads Kiilerich # Date 2016-03-02 00:14:31 # Node ID f2075ef95ae20883e0284bb500bcf4316eb38a9f # Parent d21305f7f166ad9b89d21cfef43ddce069755262 unicode: Fix unicode conversion in repo2db_mapper diff --git a/kallithea/lib/utils.py b/kallithea/lib/utils.py --- a/kallithea/lib/utils.py +++ b/kallithea/lib/utils.py @@ -543,8 +543,9 @@ def repo2db_mapper(initial_repo_list, re removed = [] # remove from database those repositories that are not in the filesystem + unicode_initial_repo_list = set(safe_unicode(name) for name in initial_repo_list) for repo in sa.query(Repository).all(): - if repo.repo_name not in initial_repo_list.keys(): + if repo.repo_name not in unicode_initial_repo_list: if remove_obsolete: log.debug("Removing non-existing repository found in db `%s`", repo.repo_name)