Skip to content

Commit 22fdda8

Browse files
author
shaunsephton
committed
merge
1 parent 601a68a commit 22fdda8

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

ckeditor/views.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,20 @@
44
from django.http import HttpResponse
55
from django.shortcuts import render_to_response
66
from django.template import RequestContext
7-
from django.views.decorators.csrf import csrf_exempt
87

98
try:
109
from PIL import Image, ImageOps
1110
except ImportError:
1211
import Image, ImageOps
13-
12+
13+
try:
14+
from django.views.decorators.csrf import csrf_exempt
15+
except ImportError:
16+
# monkey patch this with a dummy decorator which just returns the same function
17+
# (for compatability with pre-1.1 Djangos)
18+
def csrf_exempt(fn):
19+
return fn
20+
1421
THUMBNAIL_SIZE = (75, 75)
1522

1623
def exists(name):

0 commit comments

Comments
 (0)