def comment(self):\r
return self.body\r
\r
+ @property\r
+ def headline(self):\r
+ return self.absolute_parent.headline\r
+\r
@property\r
def content_object(self):\r
return self.parent.leaf\r
try:\r
ping_google()\r
except Exception:\r
- logging.debug('problem pinging google did you register you sitemap with google?')\r
+ logging.debug('problem pinging google did you register your sitemap with google?')\r
\r
def mark_deleted(self, user):\r
if super(Comment, self).mark_deleted(user):\r
self._update_parent_comment_count(1)\r
\r
def is_reply_to(self, user):\r
- inreply = re.search('@\w+', self.comment)\r
+ inreply = re.search('@\w+', self.body)\r
if inreply is not None:\r
return user.username.startswith(inreply.group(0))\r
\r
return False\r
\r
+ def get_absolute_url(self):\r
+ return self.absolute_parent.get_absolute_url() + "#%d" % self.id\r
+\r
def __unicode__(self):\r
return self.body\r
\r