summaryrefslogtreecommitdiff
path: root/app/lib/grappelli/middleware.py
diff options
context:
space:
mode:
Diffstat (limited to 'app/lib/grappelli/middleware.py')
-rw-r--r--app/lib/grappelli/middleware.py23
1 files changed, 0 insertions, 23 deletions
diff --git a/app/lib/grappelli/middleware.py b/app/lib/grappelli/middleware.py
deleted file mode 100644
index a1c45dd..0000000
--- a/app/lib/grappelli/middleware.py
+++ /dev/null
@@ -1,23 +0,0 @@
-# coding: utf-8
-
-# python imports
-import re
-
-
-class JavaScript404Patch():
- """
- Strip obsolete js files that cannot be removed
- (because they are hardcoded in django's core)
- """
- def __init__(self):
- self.strip = ['js/jquery.min', 'js/actions.min', 'js/collapse.min', 'js/calendar']
- self.re = re.compile('<script.*(%s).js"></script>\n' % '|'.join(self.strip))
-
- def process_response(self, request, response):
- if(response and "text" in response['Content-Type'] ):
- response.content = self.re.sub('',response.content)
- return response
- else:
- return response
-
-