# HG changeset patch # User Marcin Kuzminski # Date 2011-12-24 00:21:22 # Node ID ef0066e95be5fd0e422087f07a82c28ed887dd6f # Parent ff788e390497fafe2077cf0f87167ac3efebc943 fix archive download for git diff --git a/rhodecode/controllers/files.py b/rhodecode/controllers/files.py --- a/rhodecode/controllers/files.py +++ b/rhodecode/controllers/files.py @@ -369,10 +369,11 @@ class FilesController(BaseRepoController if dbrepo.enable_downloads is False: return _('downloads disabled') - # patch and reset hooks section of UI config to not run any - # hooks on fetching archives with subrepos - for k, v in c.rhodecode_repo._repo.ui.configitems('hooks'): - c.rhodecode_repo._repo.ui.setconfig('hooks', k, None) + if c.rhodecode_repo.alias == 'hg': + # patch and reset hooks section of UI config to not run any + # hooks on fetching archives with subrepos + for k, v in c.rhodecode_repo._repo.ui.configitems('hooks'): + c.rhodecode_repo._repo.ui.setconfig('hooks', k, None) cs = c.rhodecode_repo.get_changeset(revision) content_type = settings.ARCHIVE_SPECS[fileformat][0]