[tor-commits] [bridgedb/master] Return from generateQR() if the qrcode module isn't imported.

isis at torproject.org isis at torproject.org
Sat Mar 21 02:02:56 UTC 2015


commit 6293394fba0f6dbf00223435d15b301cd7fb712b
Author: Isis Lovecruft <isis at torproject.org>
Date:   Tue Feb 10 04:26:14 2015 +0000

    Return from generateQR() if the qrcode module isn't imported.
---
 lib/bridgedb/qrcodes.py |    1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/bridgedb/qrcodes.py b/lib/bridgedb/qrcodes.py
index 8016262..0aa1e8f 100644
--- a/lib/bridgedb/qrcodes.py
+++ b/lib/bridgedb/qrcodes.py
@@ -43,6 +43,7 @@ def generateQR(bridgelines, imageFormat=u'JPEG', bridgeSchema=False):
 
     if not qrcode:
         logging.info("Not creating QRCode for bridgelines; no qrcode module.")
+        return
 
     try:
         if bridgeSchema:





More information about the tor-commits mailing list