From 94b0df70c350a8a300800df1a1ebae807b2643dc Mon Sep 17 00:00:00 2001 From: Kevin Kong Date: Sat, 18 May 2024 20:48:15 +0800 Subject: [PATCH] Update usage.rst --- docs/usage.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/usage.rst b/docs/usage.rst index d9c0c99..8f046b4 100644 --- a/docs/usage.rst +++ b/docs/usage.rst @@ -66,12 +66,12 @@ the root ``ratelimit`` module: from django_ratelimit.decorators import ratelimit - @ratelimit(key='ip', method=ratelimit.ALL) - @ratelimit(key='ip', method=ratelimit.UNSAFE) + @ratelimit(key='ip', method=django_ratelimit.ALL) + @ratelimit(key='ip', method=django_ratelimit.UNSAFE) def myview(request): pass -``ratelimit.ALL`` applies to all HTTP methods. ``ratelimit.UNSAFE`` +``django_ratelimit.ALL`` applies to all HTTP methods. ``django_ratelimit.UNSAFE`` is a shortcut for ``('POST', 'PUT', 'PATCH', 'DELETE')``.