From 9a80c9f5b9201171c41776857c08ab18a78228a2 Mon Sep 17 00:00:00 2001 From: Sanjay B Date: Mon, 23 Sep 2013 20:24:19 +0530 Subject: [PATCH] try and fix ctypes issue --- itf/app/models.py | 2 +- itf/templates/search/search.html | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/itf/app/models.py b/itf/app/models.py index dbd418c..9aa3a71 100755 --- a/itf/app/models.py +++ b/itf/app/models.py @@ -125,7 +125,7 @@ class ItfModel(models.Model): def get_content_type(self): for c in ContentType.objects.filter(model=self.__class__._meta.module_name): - if c.model_class() is not None: + if c.model_class() is not None and isinstance(c.model_class(), ItfModel): return c raise diff --git a/itf/templates/search/search.html b/itf/templates/search/search.html index 21f16da..ca67be9 100755 --- a/itf/templates/search/search.html +++ b/itf/templates/search/search.html @@ -34,7 +34,6 @@

{% for result in page.object_list %} - {{ result.object }} {{ result.text|truncatewords:60|markdown|striptags }}