mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-10-03 17:50:11 +02:00
remove unused 'apps' argument from update.scan_apks()
This commit is contained in:
parent
5faef55d67
commit
47d9fd330d
@ -504,12 +504,11 @@ def insert_obbs(repodir, apps, apks):
|
||||
break
|
||||
|
||||
|
||||
def scan_apks(apps, apkcache, repodir, knownapks, use_date_from_apk=False):
|
||||
def scan_apks(apkcache, repodir, knownapks, use_date_from_apk=False):
|
||||
"""Scan the apks in the given repo directory.
|
||||
|
||||
This also extracts the icons.
|
||||
|
||||
:param apps: list of all applications, as per metadata.read_metadata
|
||||
:param apkcache: current apk cache information
|
||||
:param repodir: repo directory to scan
|
||||
:param knownapks: known apks info
|
||||
@ -1394,7 +1393,7 @@ def main():
|
||||
delete_disabled_builds(apps, apkcache, repodirs)
|
||||
|
||||
# Scan all apks in the main repo
|
||||
apks, cachechanged = scan_apks(apps, apkcache, repodirs[0], knownapks, options.use_date_from_apk)
|
||||
apks, cachechanged = scan_apks(apkcache, repodirs[0], knownapks, options.use_date_from_apk)
|
||||
|
||||
# Generate warnings for apk's with no metadata (or create skeleton
|
||||
# metadata files, if requested on the command line)
|
||||
@ -1438,7 +1437,7 @@ def main():
|
||||
|
||||
# Scan the archive repo for apks as well
|
||||
if len(repodirs) > 1:
|
||||
archapks, cc = scan_apks(apps, apkcache, repodirs[1], knownapks, options.use_date_from_apk)
|
||||
archapks, cc = scan_apks(apkcache, repodirs[1], knownapks, options.use_date_from_apk)
|
||||
if cc:
|
||||
cachechanged = True
|
||||
else:
|
||||
|
@ -101,7 +101,7 @@ class UpdateTest(unittest.TestCase):
|
||||
|
||||
apps = fdroidserver.metadata.read_metadata(xref=True)
|
||||
knownapks = fdroidserver.common.KnownApks()
|
||||
apks, cachechanged = fdroidserver.update.scan_apks(apps, {}, 'repo', knownapks, False)
|
||||
apks, cachechanged = fdroidserver.update.scan_apks({}, 'repo', knownapks, False)
|
||||
self.assertEqual(len(apks), 6)
|
||||
apk = apks[0]
|
||||
self.assertEqual(apk['minSdkVersion'], '4')
|
||||
|
Loading…
Reference in New Issue
Block a user