diff --git a/ec_api/apps/frontend/views.py b/ec_api/apps/frontend/views.py index de142ca..c0c386d 100644 --- a/ec_api/apps/frontend/views.py +++ b/ec_api/apps/frontend/views.py @@ -1,5 +1,6 @@ import requests from django.http import HttpResponse +from django.utils.decorators import method_decorator from django.views import View from django.views.decorators.cache import cache_control from django.views.generic import TemplateView @@ -16,7 +17,7 @@ class WidgetView(TemplateView): class WidgetJSView(View): - @cache_control(max_age=600) + @method_decorator(cache_control(max_age=600)) def get(self, request, *args, **kwargs): req = requests.get(WIDGET_S3_URL) req.raise_for_status()