Fixed sickragetv/sickrage-issues#162 - will always return list object even when branches do not exist

This commit is contained in:
echel0n 2014-12-18 14:04:15 -08:00
parent 340bcffc91
commit ce7873584f
1 changed files with 2 additions and 1 deletions

View File

@ -433,7 +433,8 @@ class GitUpdateManager(UpdateManager):
branches, err, exit_status = self._run_git(self._git_path, 'ls-remote --heads %s' % sickbeard.GIT_REMOTE) # @UnusedVariable
if exit_status == 0 and branches:
return re.findall('\S+\Wrefs/heads/(.*)', branches)
if branches:
return re.findall('\S+\Wrefs/heads/(.*)', branches)
return []
def update_remote_origin(self):