$_SERVER['HTTP_ACCEPT'], 'agent' => $_SERVER['HTTP_USER_AGENT'] ?? '']); return true; } return false; } /** * Get information about this site * * @return array */ public static function getSiteInfo(): array { $policies = [ Module\Register::OPEN => 'open', Module\Register::APPROVE => 'approve', Module\Register::CLOSED => 'closed', ]; return [ 'url' => (string)DI::baseUrl(), 'openWebAuth' => (string)DI::baseUrl() . '/owa', 'authRedirect' => (string)DI::baseUrl() . '/magic', 'register_policy' => $policies[Register::getPolicy()], 'accounts' => DI::keyValue()->get('nodeinfo_total_users'), 'plugins' => Addon::getVisibleList(), 'sitename' => DI::config()->get('config', 'sitename'), 'about' => DI::config()->get('config', 'info'), 'project' => App::PLATFORM, 'version' => App::VERSION, ]; } }