From ad760dbb2b1962fc425a3c9fab40b4e9cf6ee3fa Mon Sep 17 00:00:00 2001 From: Tor-Einar Skog <tor-einar.skog@bioforsk.no> Date: Fri, 9 Jan 2015 11:25:18 +0100 Subject: [PATCH] Bugfix --- information/models.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/information/models.py b/information/models.py index 8c779408..2fdff20c 100644 --- a/information/models.py +++ b/information/models.py @@ -44,9 +44,7 @@ class InformationLocale(models.Model): ) except: # Use the first and best - return InformationLocale.objects.get( - information=Information.objects.get(pk=information_id) - )[0] + return InformationLocale.objects.get(information=Information.objects.filter(pk=information_id))[0] @staticmethod def get_heading_with_fallback(information_id, language_code=translation.get_language()): -- GitLab