public function extendVisitorDetails(&$visitor, $details) { $visitor['deviceType'] = getDeviceTypeLabel($details['config_device_type']); if (!PluginManager::getInstance()->isPluginActivated('UserSettings')) { $instance = new UserSettings(); $instance->extendVisitorDetails($visitor, $details); } }
public function configure(WidgetsList $widgetsList) { $userSettings = new UserSettings(); foreach ($userSettings->getRawReportMetadata() as $report) { list($category, $name, $controllerName, $controllerAction) = $report; if ($category == false) { continue; } $widgetsList->add($category, $name, $controllerName, $controllerAction); } }