mirror of
https://github.com/onionshare/onionshare.git
synced 2024-10-01 01:35:40 -04:00
Initialize the flask app with a random static path, to avoid issue where /static doesn't work in website mode
This commit is contained in:
parent
cc2cead50b
commit
8f1e09875b
@ -68,6 +68,9 @@ class Web:
|
||||
self.app = Flask(
|
||||
__name__,
|
||||
static_folder=self.common.get_resource_path("static"),
|
||||
static_url_path="/static_".format(
|
||||
self.common.random_string(16)
|
||||
), # randomize static_url_path to avoid making /static unusable
|
||||
template_folder=self.common.get_resource_path("templates"),
|
||||
)
|
||||
self.app.secret_key = self.common.random_string(8)
|
||||
|
Loading…
Reference in New Issue
Block a user