blueloveTH пре 2 година
родитељ
комит
4ae14022ed
1 измењених фајлова са 5 додато и 1 уклоњено
  1. 5 1
      benchmarks/ldtk_cjson.py

+ 5 - 1
benchmarks/ldtk_cjson.py

@@ -7,7 +7,11 @@ import sys
 is_pkpy = not hasattr(sys, 'getrefcount')
 
 if is_pkpy:
-    import cjson as json
+    try:
+        import cjson as json
+    except ImportError:
+        print('[cJSON not Enabled]')
+        exit(0)
 else:
     import json