diff options
Diffstat (limited to 'pyaggr3g470r/views.py')
-rw-r--r-- | pyaggr3g470r/views.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/pyaggr3g470r/views.py b/pyaggr3g470r/views.py index 1118c223..65e2459f 100644 --- a/pyaggr3g470r/views.py +++ b/pyaggr3g470r/views.py @@ -147,6 +147,8 @@ def feed(feed_id=None): word_size = 6 nb_articles = models.Article.objects().count() user = models.User.objects(email=g.user.email, feeds__oid=feed_id).first() + if user == None: + return redirect(url_for('feeds')) for feed in user.feeds: if str(feed.oid) == feed_id: articles = feed.articles |