diff --git a/cookbook/serializer.py b/cookbook/serializer.py index 06d09c216..ce8d48de9 100644 --- a/cookbook/serializer.py +++ b/cookbook/serializer.py @@ -475,7 +475,7 @@ class StepSerializer(WritableNestedModelSerializer, ExtendedRecipeMixin): # check if root type is recipe to prevent infinite recursion # can be improved later to allow multi level embedding if obj.step_recipe and type(self.parent.root) == RecipeSerializer: - return StepRecipeSerializer(obj.step_recipe).data + return StepRecipeSerializer(obj.step_recipe, context={'request': self.context['request']}).data class Meta: model = Step