From cc8164ef4c5774ab209fe63ef892371c6b7b250f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torma=20Krist=C3=B3f?= Date: Sun, 13 Feb 2022 21:30:13 +0100 Subject: [PATCH] use back_populates instead of backref --- mealapi/model/meal.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mealapi/model/meal.py b/mealapi/model/meal.py index 1f5ebe0..b2dfb24 100644 --- a/mealapi/model/meal.py +++ b/mealapi/model/meal.py @@ -12,4 +12,4 @@ class Meal(db.Model): spicy = db.Column(db.Boolean, nullable=True, default=False) vegan = db.Column(db.Boolean, nullable=True, default=False) glutenfree = db.Column(db.Boolean, nullable=True, default=False) - ingredients = db.relationship('Ingredient', backref='Meal', lazy='dynamic') + ingredients = db.relationship('Ingredient', back_populates='Meal', lazy='dynamic')