mirror of
https://github.com/DarkflameUniverse/NexusDashboard.git
synced 2024-08-30 18:12:11 +00:00
fixes it
This commit is contained in:
parent
35ee0ed457
commit
a07515cdb2
@ -147,10 +147,11 @@ def brick_list():
|
||||
return response
|
||||
|
||||
|
||||
@luclient_blueprint.route('/ldddb/<path>')
|
||||
def dir_listing(path):
|
||||
@luclient_blueprint.route('/ldddb/', defaults={'req_path': ''})
|
||||
@luclient_blueprint.route('/ldddb/<path:req_path>')
|
||||
def dir_listing(req_path):
|
||||
# Joining the base and the requested path
|
||||
rel_path = pathlib.Path(str(pathlib.Path(f'app/luclient/res/{path}').resolve()))
|
||||
rel_path = pathlib.Path(str(pathlib.Path(f'app/luclient/res/{req_path}').resolve()))
|
||||
# Return 404 if path doesn't exist
|
||||
if not rel_path.exists():
|
||||
return abort(404)
|
||||
|
Loading…
Reference in New Issue
Block a user