mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-05 15:00:30 +03:00
Map apps in memory from appid to appinfo
Instead of storing them in a list and doing linear searches by appinfo['id']
This commit is contained in:
parent
880f75110e
commit
94c29f9c37
11 changed files with 108 additions and 113 deletions
|
|
@ -265,14 +265,12 @@ def main():
|
|||
sys.exit(1)
|
||||
|
||||
# Make sure it's actually new...
|
||||
for app in apps:
|
||||
if app['id'] == package:
|
||||
logging.error("Package " + package + " already exists")
|
||||
sys.exit(1)
|
||||
if package in apps:
|
||||
logging.error("Package " + package + " already exists")
|
||||
sys.exit(1)
|
||||
|
||||
# Construct the metadata...
|
||||
app = metadata.parse_metadata(None)
|
||||
app['id'] = package
|
||||
app = metadata.parse_metadata(None)[1]
|
||||
app['Web Site'] = website
|
||||
app['Source Code'] = sourcecode
|
||||
if issuetracker:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue