mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-07-29 12:09:37 +00:00
gitweb: Set proper access after restoration of a backup
Otherwise, if the backup contains public repos and state before backup is all private repos, then gitweb interface is not available publicly after restore. Similar case happens when all restore repos are private and state before that contains a public repos. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
parent
8694849701
commit
ef5c2ab908
@ -184,6 +184,11 @@ def diagnose():
|
||||
return results
|
||||
|
||||
|
||||
def restore_post(packet):
|
||||
"""Update access after restoration of backups."""
|
||||
app.update_service_access()
|
||||
|
||||
|
||||
def have_public_repos(repos):
|
||||
"""Check for public repositories"""
|
||||
return any((repo['access'] == 'public' for repo in repos))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user