saveSettings($params)) { if ($title && $title != $widget->title) { $widget->title = $title; $widget->save(); } elgg_set_page_owner_guid($widget->getContainerGUID()); if ($context) { elgg_push_context($context); } echo elgg_view('object/widget/elements/content', ['entity' => $widget]); if ($context) { elgg_pop_context(); } } else { register_error(elgg_echo('widgets:save:failure')); } // widgets context elgg_pop_context(); if ($default_widgets) { elgg_pop_context(); } forward(REFERER);