incubator-allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brond...@apache.org
Subject [2/2] git commit: fixup! [#5086] avoid errors on already orphaned BlogPostSnapshot instances
Date Mon, 08 Oct 2012 22:24:12 GMT
fixup! [#5086] avoid errors on already orphaned BlogPostSnapshot instances


Project: http://git-wip-us.apache.org/repos/asf/incubator-allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-allura/commit/b5052799
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/b5052799
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/b5052799

Branch: refs/heads/db/5086
Commit: b5052799018ea7051a210ec6bf2c0786be831dac
Parents: 8ee4592
Author: Dave Brondsema <dbrondsema@geek.net>
Authored: Mon Oct 8 22:21:53 2012 +0000
Committer: Dave Brondsema <dbrondsema@geek.net>
Committed: Mon Oct 8 22:21:53 2012 +0000

----------------------------------------------------------------------
 ForgeBlog/forgeblog/model/blog.py |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/b5052799/ForgeBlog/forgeblog/model/blog.py
----------------------------------------------------------------------
diff --git a/ForgeBlog/forgeblog/model/blog.py b/ForgeBlog/forgeblog/model/blog.py
index 3ee4949..50e8e1c 100644
--- a/ForgeBlog/forgeblog/model/blog.py
+++ b/ForgeBlog/forgeblog/model/blog.py
@@ -61,7 +61,7 @@ class BlogPostSnapshot(M.Snapshot):
         result = super(BlogPostSnapshot, self).index()
         result.update(
             title_s='Version %d of %s' % (
-                self.version, self.original().shorthand_id()),
+                self.version, orig.shorthand_id()),
             type_s=self.type_s,
             text=self.data.text)
         return result
@@ -76,14 +76,14 @@ class BlogPostSnapshot(M.Snapshot):
         orig = self.original()
         if not orig:
             return None
-        return self.original().attachments
+        return orig.attachments
 
     @property
     def email_address(self):
         orig = self.original()
         if not orig:
             return None
-        return self.original().email_address
+        return orig.email_address
 
 class BlogPost(M.VersionedArtifact, ActivityObject):
     class __mongometa__:


Mime
View raw message