mirror of
https://github.com/morpheus65535/bazarr.git
synced 2024-11-10 17:13:35 +08:00
Fixed unwanted injection of variables on API endpoints.
This commit is contained in:
parent
5a98dfcf83
commit
b0f743767b
1 changed files with 7 additions and 5 deletions
|
@ -74,12 +74,14 @@ def catch_all(path):
|
|||
updated = '0'
|
||||
|
||||
inject = dict()
|
||||
inject["baseUrl"] = base_url
|
||||
inject["canUpdate"] = not args.no_update
|
||||
inject["hasUpdate"] = updated != '0'
|
||||
|
||||
if auth:
|
||||
inject["apiKey"] = settings.auth.apikey
|
||||
if not path.startswith('api/'):
|
||||
inject["baseUrl"] = base_url
|
||||
inject["canUpdate"] = not args.no_update
|
||||
inject["hasUpdate"] = updated != '0'
|
||||
|
||||
if auth:
|
||||
inject["apiKey"] = settings.auth.apikey
|
||||
|
||||
template_url = base_url
|
||||
if not template_url.endswith("/"):
|
||||
|
|
Loading…
Reference in a new issue