We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit 00fb5fef authored by Brion Vibber's avatar Brion Vibber

Cleanup undefined variable notice: set a couple more null defaults for new...

Cleanup undefined variable notice: set a couple more null defaults for new params in Notice::saveNew().

Fixes this notice seen while using AJAX repeat button:
Notice: Undefined variable: uri in classes/Notice.php on line 243
parent e2e18436
......@@ -176,12 +176,13 @@ class Notice extends Memcached_DataObject
}
static function saveNew($profile_id, $content, $source, $options=null) {
$defaults = array('uri' => null,
'reply_to' => null,
'repeat_of' => null);
if (!empty($options)) {
$options = $options + $defaults;
extract($options);
if (!isset($reply_to)) {
$reply_to = NULL;
}
}
if (empty($is_local)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment