From 4ae8bccf962fd811e851391a091b25486af7814d Mon Sep 17 00:00:00 2001 From: Bertrand Bordage Date: Fri, 19 Jun 2015 19:46:10 +0200 Subject: [PATCH] Fixes Python 3 compatibility. --- cachalot/utils.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cachalot/utils.py b/cachalot/utils.py index 0a8129b..85114dc 100644 --- a/cachalot/utils.py +++ b/cachalot/utils.py @@ -3,7 +3,6 @@ from __future__ import unicode_literals from hashlib import sha1 from time import time -from types import NoneType import django from django.db import connections @@ -24,7 +23,7 @@ class UncachableQuery(Exception): pass -CACHABLE_PARAM_TYPES = (bool, int, binary_type, text_type, NoneType) +CACHABLE_PARAM_TYPES = (bool, int, binary_type, text_type, type(None)) def get_query_cache_key(compiler): """