| Conditions | 2 |
| Paths | 2 |
| Total Lines | 19 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 2 | ||
| Bugs | 1 | Features | 0 |
| 1 | <?php |
||
| 25 | public function get() |
||
| 26 | { |
||
| 27 | $objectManager = new ObjectManager(); |
||
| 28 | $configurationRepository = $objectManager->get(ConfigurationRepository::class); |
||
| 29 | |||
| 30 | /** @var \HDNET\OnpageIntegration\Domain\Model\Configuration $configuration */ |
||
| 31 | $configuration = $configurationRepository->findRecord(1); |
||
| 32 | |||
| 33 | if (!$configuration) { |
||
| 34 | throw new UnavailableAccessDataException; |
||
| 35 | } |
||
| 36 | |||
| 37 | $buildAuth = [ |
||
| 38 | 'api_key' => $configuration->getApiKey(), |
||
| 39 | 'project' => $configuration->getProjectId(), |
||
| 40 | ]; |
||
| 41 | |||
| 42 | return $buildAuth; |
||
| 43 | } |
||
| 44 | } |
||
| 45 |