Skip to content
Snippets Groups Projects
Commit f9b4cf66 authored by Srdjan Grubor's avatar Srdjan Grubor
Browse files

Fixed issues with null descriptions

API changed to now include nulls in descriptions so we needed to account
for that case in the logic.
parent 741eecc1
No related branches found
No related tags found
No related merge requests found
......@@ -119,7 +119,7 @@ class CodeRepo(object):
self.full_name = gh_repo.full_name
self.ssh_url = gh_repo.ssh_url
self.default_branch = gh_repo.default_branch
self.description = gh_repo.description
self.description = gh_repo.description or ""
self.target_directory = os.path.join(self.config.cwd, self.name)
if self.config.mirror:
......@@ -207,6 +207,10 @@ class WikiRepo(CodeRepo):
self.ssh_url = self.ssh_url.rpartition('.git')[0] \
+ '.wiki.git'
self.default_branch = 'master'
if self.description == None:
self.description = gh_repo.name
self.description += ' - Wiki'
def try_clone(self, ignore_error=True):
......@@ -226,7 +230,7 @@ class JsonRepo(object):
self.name = gh_repo.name
self.full_name = gh_repo.full_name
self.repo_url = gh_repo.url
self.description = gh_repo.description
self.description = gh_repo.description or ""
# Sanitize the content url to strip the {/number} type markers
self.content_url = api_url.split('{')[0]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment