summaryrefslogtreecommitdiff
path: root/classes
diff options
context:
space:
mode:
authorEvan Prodromou <evan@status.net>2010-02-21 09:17:00 -0500
committerEvan Prodromou <evan@status.net>2010-02-21 09:17:00 -0500
commit9498a164805892a8af17311f7e7697b132524990 (patch)
tree899e96ac624b5cb1db4d70dad4c71e37f7bf736d /classes
parent6169d8a877fb0e76ee17187f74a6747fe7f2c97d (diff)
Notice::saveNew() accepts url and rendered options
Diffstat (limited to 'classes')
-rw-r--r--classes/Notice.php10
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