incubator-allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From john...@apache.org
Subject [2/7] git commit: [#7229] Handle activity objects not having project attribute gracefully on user profile
Date Tue, 04 Mar 2014 16:17:17 GMT
[#7229] Handle activity objects not having project attribute gracefully on user profile

Signed-off-by: Cory Johns <cjohns@slashdotmedia.com>


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

Branch: refs/heads/cj/7204
Commit: adf92cf18c2ac332ad41865d684a8bb7c9506938
Parents: d26d6e5
Author: Cory Johns <cjohns@slashdotmedia.com>
Authored: Mon Mar 3 15:47:35 2014 +0000
Committer: Cory Johns <cjohns@slashdotmedia.com>
Committed: Mon Mar 3 15:47:35 2014 +0000

----------------------------------------------------------------------
 ForgeActivity/forgeactivity/main.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/adf92cf1/ForgeActivity/forgeactivity/main.py
----------------------------------------------------------------------
diff --git a/ForgeActivity/forgeactivity/main.py b/ForgeActivity/forgeactivity/main.py
index 6af2da8..37c7ff5 100644
--- a/ForgeActivity/forgeactivity/main.py
+++ b/ForgeActivity/forgeactivity/main.py
@@ -265,7 +265,7 @@ class ForgeActivityProfileSection(ProfileSectionBase):
             # calls are made by perm_check() above.
             session(activity).expunge(activity)
             activity_obj = get_activity_object(activity.obj)
-            activity.obj.project = activity_obj.project if activity_obj else None
+            activity.obj.project = getattr(activity_obj, 'project', None)
 
         context.update({
             'follow_toggle': W.follow_toggle,


Mime
View raw message