| Conditions | 3 |
| Paths | 2 |
| Total Lines | 14 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 36 | public function create($paramType, $name, array $options) |
||
| 37 | { |
||
| 38 | if ('federation-upstream' != $paramType && 'federation-upstream-set' != $paramType) { |
||
| 39 | $this->logger->critical(sprintf('ParameterType: %s is not supported. Only federation-upstream & federation-upstream-set', $paramType)); |
||
| 40 | return; |
||
| 41 | } |
||
| 42 | |||
| 43 | $this->client->query( |
||
| 44 | ClientInterface::METHOD_PUT, |
||
| 45 | sprintf('/api/parameters/%s/%s/%s', $paramType, $this->vhost, $name), |
||
| 46 | ['value' => $options]); |
||
| 47 | |||
| 48 | $this->logger->info(sprintf('Create parameter type: <info>%s</info> and name: <info>%s</info>', $paramType, $name)); |
||
| 49 | } |
||
| 50 | } |
||
| 51 |