config = $config; $this->l = $l; } /** * @return string */ public function getCategory() { return 'encryption'; } /** * @return string */ public function getDisplayName() { return $this->l->t('Encryption information (is it enabled?, what is the default module)'); } /** * @return array (string => string|int) */ public function getData() { $data = [ 'enabled' => $this->config->getAppValue('core', 'encryption_enabled', 'no') === 'yes' ? 'yes' : 'no', 'default_module' => $this->config->getAppValue('core', 'default_encryption_module') === 'OC_DEFAULT_MODULE' ? 'yes' : 'no', ]; if ($data['enabled'] === 'yes') { unset($data['default_module']); } return $data; } }