summaryrefslogtreecommitdiff
path: root/classes
diff options
context:
space:
mode:
authorEvan Prodromou <evan@status.net>2010-02-27 17:07:57 -0500
committerEvan Prodromou <evan@status.net>2010-02-27 17:07:57 -0500
commitf00e8bbf47e3ea93578c5bfaba8d1d0460526086 (patch)
treec60faae494a2e43bdf45e7508c4ac2bd763399b5 /classes
parentb701f5648d944cbb74748c48ea399b226eafc525 (diff)
parent04c4facba9230f40726c5891dcac21d928fbb2ab (diff)
Merge branch 'testing' into 0.9.x
Diffstat (limited to 'classes')
-rw-r--r--classes/Notice.php19
1 files changed, 12 insertions, 7 deletions
diff --git a/classes/Notice.php b/classes/Notice.php
index ac4640534..3702dbcfa 100644
--- a/classes/Notice.php
+++ b/classes/Notice.php
@@ -282,12 +282,6 @@ class Notice extends Memcached_DataObject
$notice->content = $final;
- if (!empty($rendered)) {
- $notice->rendered = $rendered;
- } else {
- $notice->rendered = common_render_content($final, $notice);
- }
-
$notice->source = $source;
$notice->uri = $uri;
$notice->url = $url;
@@ -315,6 +309,12 @@ class Notice extends Memcached_DataObject
$notice->location_ns = $location_ns;
}
+ if (!empty($rendered)) {
+ $notice->rendered = $rendered;
+ } else {
+ $notice->rendered = common_render_content($final, $notice);
+ }
+
if (Event::handle('StartNoticeSave', array(&$notice))) {
// XXX: some of these functions write to the DB
@@ -944,6 +944,8 @@ class Notice extends Memcached_DataObject
$reply->profile_id = $user->id;
$id = $reply->insert();
+
+ self::blow('reply:stream:%d', $user->id);
}
}
@@ -971,7 +973,10 @@ class Notice extends Memcached_DataObject
$sender = Profile::staticGet($this->profile_id);
- $mentions = common_find_mentions($this->profile_id, $this->content);
+ // @todo ideally this parser information would only
+ // be calculated once.
+
+ $mentions = common_find_mentions($this->content, $this);
$replied = array();