(?string $id)
| 330 | } |
| 331 | |
| 332 | public static function getSource(?string $id): ?array |
| 333 | { |
| 334 | if (self::proSourcesAvailable()) { |
| 335 | return ProSources::getSource($id); |
| 336 | } |
| 337 | |
| 338 | $cfg = self::coreConfigFromRaw(self::loadRaw()); |
| 339 | $id = trim((string)$id); |
| 340 | if ($id !== '' && isset($cfg['sources'][$id])) { |
| 341 | return self::buildSourceView($cfg['sources'][$id], true, false); |
| 342 | } |
| 343 | |
| 344 | return null; |
| 345 | } |
| 346 | |
| 347 | public static function getFirstEnabledSource(): ?array |
| 348 | { |
no test coverage detected