From a6769fc5f2c84aa079944d28a6b6505c3cc12370 Mon Sep 17 00:00:00 2001 From: François Schmidts Date: Tue, 3 Mar 2015 22:16:24 +0100 Subject: fixing the multi api --- pyaggr3g470r/models/article.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'pyaggr3g470r/models') diff --git a/pyaggr3g470r/models/article.py b/pyaggr3g470r/models/article.py index 2b79c6aa..0466bc35 100644 --- a/pyaggr3g470r/models/article.py +++ b/pyaggr3g470r/models/article.py @@ -83,5 +83,5 @@ class Article(db.Model): "like": self.like, "date": self.date, "retrieved_date": self.retrieved_date, - "feed_id": self.source.id, - "feed_name": self.source.title} + "feed_id": getattr(self.source, 'id', None), + "feed_name": getattr(self.source, 'title', None)} -- cgit