ensure that mirror URLs always include the repodir

Since the mirror URLs are per repo section (repo/archive), the mirror URLs
must include the repodir at the end.  This was missing for servergitmirrors

found by @cde when working on fdroidclient#35
This commit is contained in:
Hans-Christoph Steiner 2017-07-07 15:50:11 +02:00
parent 70858bb104
commit 25f96e1911
2 changed files with 8 additions and 3 deletions

View file

@ -113,8 +113,8 @@ def make(apps, sortedids, apks, repodir, archive):
mirrors.append(urllib.parse.urljoin(mirror + '/', urlbasepath))
for mirror in common.config.get('servergitmirrors', []):
mirror = get_mirror_service_url(mirror)
if mirror is not None:
mirrors.append(mirror + '/')
if mirror:
mirrors.append(mirror + '/' + repodir)
if mirrorcheckfailed:
raise FDroidException("Malformed repository mirrors.")
if mirrors: