This commit is contained in:
parent
88bbeded0f
commit
d539472905
@ -17,6 +17,7 @@ class MealBaseResource(Resource):
|
||||
|
||||
try:
|
||||
self.mealschema.load(body, session=db.session)
|
||||
db.session.commit()
|
||||
return '', 204
|
||||
except ValidationError as error:
|
||||
abort(406, error.messages)
|
||||
|
@ -6,7 +6,6 @@ from .ingredientschema import IngredientSchema
|
||||
|
||||
class MealSchema(ma.SQLAlchemyAutoSchema):
|
||||
|
||||
# A list of author objects
|
||||
ingredients = ma.Nested(IngredientSchema, many=True)
|
||||
|
||||
class Meta:
|
||||
|
Loading…
Reference in New Issue
Block a user