aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework/throttling.py
diff options
context:
space:
mode:
authorTom Christie2013-08-19 20:58:28 +0100
committerTom Christie2013-08-19 20:58:28 +0100
commit28e44efe25b5373f0f46357e4e26f7cb0482efa6 (patch)
tree9dd36c65ade4b801cfb7e93be7123fc5a5fb69e4 /rest_framework/throttling.py
parent9e4e2c60f75f596d3f9e32deaab23bf98fc8ef0f (diff)
parent34d65119fc1c200b76a8af7213a92d6b279bd478 (diff)
downloaddjango-rest-framework-28e44efe25b5373f0f46357e4e26f7cb0482efa6.tar.bz2
Merge branch 'master' into 2.4.0
Diffstat (limited to 'rest_framework/throttling.py')
-rw-r--r--rest_framework/throttling.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/rest_framework/throttling.py b/rest_framework/throttling.py
index f6bb1cc8..65b45593 100644
--- a/rest_framework/throttling.py
+++ b/rest_framework/throttling.py
@@ -96,6 +96,9 @@ class SimpleRateThrottle(BaseThrottle):
return True
self.key = self.get_cache_key(request, view)
+ if self.key is None:
+ return True
+
self.history = cache.get(self.key, [])
self.now = self.timer()