mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-05 15:00:30 +03:00
common: do not use module reference for local functions
This just makes things more confusing.
This commit is contained in:
parent
8208841460
commit
1eaba25021
1 changed files with 2 additions and 2 deletions
|
|
@ -380,7 +380,7 @@ def get_config(opts=None):
|
||||||
if config is not None:
|
if config is not None:
|
||||||
return config
|
return config
|
||||||
|
|
||||||
common.read_config(opts=opts)
|
read_config(opts=opts)
|
||||||
|
|
||||||
# make sure these values are available in common.py even if they didn't
|
# make sure these values are available in common.py even if they didn't
|
||||||
# declare global in a scope
|
# declare global in a scope
|
||||||
|
|
@ -570,7 +570,7 @@ def parse_mirrors_config(mirrors):
|
||||||
def file_entry(filename, hash_value=None):
|
def file_entry(filename, hash_value=None):
|
||||||
meta = {}
|
meta = {}
|
||||||
meta["name"] = "/" + Path(filename).as_posix().split("/", 1)[1]
|
meta["name"] = "/" + Path(filename).as_posix().split("/", 1)[1]
|
||||||
meta["sha256"] = hash_value or common.sha256sum(filename)
|
meta["sha256"] = hash_value or sha256sum(filename)
|
||||||
meta["size"] = os.stat(filename).st_size
|
meta["size"] = os.stat(filename).st_size
|
||||||
return meta
|
return meta
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue