Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Only cache the ingredient overview

Roland Geiderdc3b43d315fd
diff --git a/wger/nutrition/api/views.py b/wger/nutrition/api/views.py
index 4c2de3c4c..e34879cc5 100644
--- a/wger/nutrition/api/views.py
+++ b/wger/nutrition/api/views.py
@@ -92,8 +92,8 @@ class IngredientViewSet(viewsets.ReadOnlyModelViewSet):
)
@method_decorator(cache_page(settings.WGER_SETTINGS['EXERCISE_CACHE_TTL']))
- def dispatch(self, request, *args, **kwargs):
- return super().dispatch(request, *args, **kwargs)
+ def list(self, request, *args, **kwargs):
+ return super().list(request, *args, **kwargs)
@action(detail=True)
def get_values(self, request, pk):