]> git.mxchange.org Git - friendica.git/blobdiff - src/Module/Bookmarklet.php
Remove direct calls to App->user
[friendica.git] / src / Module / Bookmarklet.php
index fab9dbc6c59e56fcc243d6744bad021b78b99c4f..9db1cc1381ea2918facd523c056acdf6a7cfb4e9 100644 (file)
@@ -60,10 +60,10 @@ class Bookmarklet extends BaseModule
 
                        $x = [
                                'is_owner'         => true,
-                               'allow_location'   => $app->user['allow_location'],
-                               'default_location' => $app->user['default-location'],
-                               'nickname'         => $app->user['nickname'],
-                               'lockstate'        => ((is_array($app->user) && ((strlen($app->user['allow_cid'])) || (strlen($app->user['allow_gid'])) || (strlen($app->user['deny_cid'])) || (strlen($app->user['deny_gid'])))) ? 'lock' : 'unlock'),
+                               'allow_location'   => $app->getUserValue('allow_location'),
+                               'default_location' => $app->getUserValue('default-location'),
+                               'nickname'         => $app->getNickname(),
+                               'lockstate'        => ACL::getLockstateForUserId($app->getUserId()) ? 'lock' : 'unlock',
                                'default_perms'    => ACL::getDefaultUserPermissions($app->user),
                                'acl'              => ACL::getFullSelectorHTML(DI::page(), $app->user, true),
                                'bang'             => '',