From 03968928e7f4015ccb9e510d6049725777a2f7b7 Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Tue, 24 Mar 2020 10:29:22 +0100 Subject: [PATCH] Don't do QRcode plugin base imports, or the web app may fail if the dependencies are not installed --- platypush/backend/http/app/routes/plugins/qrcode/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platypush/backend/http/app/routes/plugins/qrcode/__init__.py b/platypush/backend/http/app/routes/plugins/qrcode/__init__.py index dfb68407..c8fd7e3f 100644 --- a/platypush/backend/http/app/routes/plugins/qrcode/__init__.py +++ b/platypush/backend/http/app/routes/plugins/qrcode/__init__.py @@ -4,7 +4,6 @@ from flask import abort, request, Blueprint, Response from platypush.backend.http.app import template_folder from platypush.context import get_plugin -from platypush.plugins.qrcode import QrcodePlugin qrcode = Blueprint('qrcode', __name__, template_folder=template_folder) @@ -20,6 +19,7 @@ def generate_code(): This route can be used to generate a QR code given a ``content`` parameter. """ + from platypush.plugins.qrcode import QrcodePlugin content = request.args.get('content') if not content: abort(400, 'Expected content parmeter')