Fixes for make paramecio2 more portable

This commit is contained in:
absurdo 2024-04-24 13:00:30 +02:00
parent 2599eabed0
commit f993143936
5 changed files with 12 additions and 2 deletions

View file

@ -25,6 +25,11 @@ import sys
import inspect
from paramecio2.libraries.datetime import set_timezone
swagger_app=False
if hasattr(config, 'swagger_app'):
swagger_app=config.swagger_app
def start_app():
set_timezone()
@ -121,4 +126,8 @@ def start_app():
return send_file(file_path)
if swagger_app:
from flasgger import Swagger
swagger=Swagger(app)
return app