X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=planets%2Fplanets.php;h=2937c0360ed3c32596638b66665e0126df576060;hb=2e9b8111fb09fd64d06e28128c0fbafa2a448c03;hp=8a206fb51641c2bd46df0f514b39a403b4fe9aaa;hpb=82073db292d8f5bacdbffab8b94347f3bae1b271;p=friendica-addons.git diff --git a/planets/planets.php b/planets/planets.php index 8a206fb5..2937c036 100644 --- a/planets/planets.php +++ b/planets/planets.php @@ -81,38 +81,28 @@ function planets_post_hook(&$item) return; } - - - /** - * * Callback from the settings post function. * $post contains the $_POST array. * We will make sure we've got a valid user account * and if so set our configuration setting for this person. - * */ - -function planets_settings_post($post) +function planets_settings_post(array $post) { if (!DI::userSession()->getLocalUserId()) { return; } - if ($_POST['planets-submit']) { - DI::pConfig()->set(DI::userSession()->getLocalUserId(), 'planets', 'enable' ,intval($_POST['planets'])); + if ($post['planets-submit']) { + DI::pConfig()->set(DI::userSession()->getLocalUserId(), 'planets', 'enable' ,intval($post['planets'])); } } /** - * * Called from the Addon Setting form. * Add our own settings info to the page. * */ - - - function planets_settings(array &$data) { if(!DI::userSession()->getLocalUserId()) {