From 8efb262f2f1a58b3ce30d16d376bc64a56a24119 Mon Sep 17 00:00:00 2001 From: Joseph Spiros Date: Tue, 22 Jun 2010 12:11:41 -0400 Subject: [PATCH] Pre-merge cleanup. --- admin.py | 2 +- validators.py | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/admin.py b/admin.py index 5685f14..9e991d9 100644 --- a/admin.py +++ b/admin.py @@ -253,7 +253,7 @@ class PageAdmin(NodeAdmin): contentreference = page.contentreferences.get(name=container_name) except ContentReference.DoesNotExist: contentreference = ContentReference(name=container_name, page=page, content_type=container_content_type) - + if content == None: contentreference.content_id = None else: diff --git a/validators.py b/validators.py index 1e73c0b..0c6fa78 100644 --- a/validators.py +++ b/validators.py @@ -44,8 +44,8 @@ class TreeParentValidator(object): def get_message(self): return self.static_message or _(u"A %s can't be its own parent." % self.instance.__class__.__name__) message = property(get_message) - - + + class TreePositionValidator(object): code = 'invalid' @@ -54,7 +54,7 @@ class TreePositionValidator(object): self.slug = slug self.obj_class = obj_class self.static_message = message - + if code is not None: self.code = code @@ -71,7 +71,7 @@ class TreePositionValidator(object): if obj.id != value.id: raise ValidationError(self.message) - + except self.obj_class.DoesNotExist: pass -- 2.20.1