Fix in loading images with python
This commit is contained in:
parent
52fa9a604f
commit
9651085e4c
2 changed files with 5 additions and 4 deletions
|
|
@ -183,10 +183,11 @@ if config.yes_static==True:
|
|||
mimetype=guess_type(path+'/'+filename)
|
||||
return static_file(filename, root=path, mimetype=mimetype[0])
|
||||
|
||||
else:
|
||||
mimetype=guess_type(path_module+'/'+filename)
|
||||
elif os.path.isfile(file_path_module):
|
||||
mimetype=guess_type(file_path_module)
|
||||
return static_file(filename, root=path_module, mimetype=mimetype[0])
|
||||
|
||||
else:
|
||||
abort(404, 'File not found')
|
||||
|
||||
def error_handler_500(e):
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ build-backend = "flit_core.buildapi"
|
|||
name = "cuchulu"
|
||||
authors = [{name = "Antonio de la Rosa", email = "antonio.delarosa@cuchulu.com"}]
|
||||
readme = "README.md"
|
||||
version = "1.0.39.1"
|
||||
version = "1.0.39.2"
|
||||
description = "A simple framework using bottle and mako"
|
||||
# dynamic = ["version", "description"]
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue