| @@ 133-140 (lines=8) @@ | ||
| 130 | * |
|
| 131 | * @return string |
|
| 132 | */ |
|
| 133 | public function getAppValue(string $key): string { |
|
| 134 | $defaultValue = null; |
|
| 135 | if (array_key_exists($key, $this->defaults)) { |
|
| 136 | $defaultValue = $this->defaults[$key]; |
|
| 137 | } |
|
| 138 | ||
| 139 | return (string) $this->config->getAppValue(Application::APP_NAME, $key, $defaultValue); |
|
| 140 | } |
|
| 141 | ||
| 142 | /** |
|
| 143 | * Set a value by key |
|
| @@ 181-190 (lines=10) @@ | ||
| 178 | * |
|
| 179 | * @return string |
|
| 180 | */ |
|
| 181 | public function getUserValue(string $key): string { |
|
| 182 | $defaultValue = null; |
|
| 183 | if (array_key_exists($key, $this->defaults)) { |
|
| 184 | $defaultValue = $this->defaults[$key]; |
|
| 185 | } |
|
| 186 | ||
| 187 | return $this->config->getUserValue( |
|
| 188 | $this->userId, Application::APP_NAME, $key, $defaultValue |
|
| 189 | ); |
|
| 190 | } |
|
| 191 | ||
| 192 | ||
| 193 | /** |
|