@property\r
def node(self):\r
if self.activity_type in (const.TYPE_ACTIVITY_ANSWER, const.TYPE_ACTIVITY_ASK_QUESTION,\r
- const.TYPE_ACTIVITY_MARK_ANSWER, const.TYPE_ACTIVITY_UPDATE_QUESTION):\r
+ const.TYPE_ACTIVITY_MARK_ANSWER):\r
return self.content_object\r
\r
- if self.activity_type in (const.TYPE_ACTIVITY_COMMENT_QUESTION,\r
- const.TYPE_ACTIVITY_COMMENT_ANSWER, const.TYPE_ACTIVITY_UPDATE_ANSWER):\r
- return self.content_object.node.leaf\r
+ if self.activity_type in (const.TYPE_ACTIVITY_COMMENT_QUESTION, const.TYPE_ACTIVITY_COMMENT_ANSWER):\r
+ return self.content_object.parent.leaf\r
+\r
+ if self.activity_type in (const.TYPE_ACTIVITY_UPDATE_ANSWER, const.TYPE_ACTIVITY_UPDATE_QUESTION):\r
+ return self.content_object.node.leaf \r
\r
raise NotImplementedError()\r
\r