diff options
author | Evan Prodromou <evan@status.net> | 2010-02-21 09:17:00 -0500 |
---|---|---|
committer | Evan Prodromou <evan@status.net> | 2010-02-21 09:17:00 -0500 |
commit | 9498a164805892a8af17311f7e7697b132524990 (patch) | |
tree | 899e96ac624b5cb1db4d70dad4c71e37f7bf736d | |
parent | 6169d8a877fb0e76ee17187f74a6747fe7f2c97d (diff) |
Notice::saveNew() accepts url and rendered options
-rw-r--r-- | classes/Notice.php | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/classes/Notice.php b/classes/Notice.php index 8b8f90474..0051cf885 100644 --- a/classes/Notice.php +++ b/classes/Notice.php @@ -194,6 +194,7 @@ class Notice extends Memcached_DataObject */ static function saveNew($profile_id, $content, $source, $options=null) { $defaults = array('uri' => null, + 'url' => null, 'reply_to' => null, 'repeat_of' => null); @@ -256,9 +257,16 @@ class Notice extends Memcached_DataObject } $notice->content = $final; - $notice->rendered = common_render_content($final, $notice); + + if (!empty($rendered)) { + $notice->rendered = $rendered; + } else { + $notice->rendered = common_render_content($final, $notice); + } + $notice->source = $source; $notice->uri = $uri; + $notice->url = $url; // Handle repeat case |