Memorize if ujson is loaded.

This commit is contained in:
Alex Root Junior 2017-07-25 04:35:17 +03:00
parent 3eba1c25c7
commit ea611e9fc9

View file

@ -1,7 +1,9 @@
try:
import ujson as json
IS_UJSON = True
except ImportError:
import json
IS_UJSON = False
def dumps(data):