return $r;
}
-function curweather_network_mod_init(App $a, string &$body)
+function curweather_network_mod_init(string &$body)
{
if (!intval(DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'curweather', 'curweather_enable'))) {
return;
DI::page()['aside'] = $curweather . DI::page()['aside'];
}
-function curweather_addon_settings_post(App $a, $post)
+function curweather_addon_settings_post($post)
{
if (!DI::userSession()->getLocalUserId() || empty($_POST['curweather-settings-submit'])) {
return;
DI::pConfig()->set(DI::userSession()->getLocalUserId(), 'curweather', 'curweather_units' , trim($_POST['curweather_units']));
}
-function curweather_addon_settings(App $a, array &$data)
+function curweather_addon_settings(array &$data)
{
if (!DI::userSession()->getLocalUserId()) {
return;
// Config stuff for the admin panel to let the admin of the node set a APPID
// for accessing the API of openweathermap
-function curweather_addon_admin_post(App $a)
+function curweather_addon_admin_post()
{
- if (!$a->isSiteAdmin()) {
+ if (!DI::userSession()->isSiteAdmin()) {
return;
}
}
}
-function curweather_addon_admin(App $a, string &$o)
+function curweather_addon_admin(string &$o)
{
- if (!$a->isSiteAdmin()) {
+ if (!DI::userSession()->isSiteAdmin()) {
return;
}