| Conditions | 2 |
| Paths | 3 |
| Total Lines | 17 |
| Code Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 19 | public function send(string $url, array $data): array |
||
| 20 | { |
||
| 21 | ini_set('soap.wsdl_cache_enabled', '0'); |
||
| 22 | try { |
||
| 23 | $client = new SoapClient($url, ['encoding' => 'UTF-8']); |
||
| 24 | $response = [ |
||
| 25 | 'status' => true, |
||
| 26 | 'providerResult' => $client->AddSchedule($data), |
||
| 27 | ]; |
||
| 28 | } catch (\SoapFault $sf) { |
||
| 29 | $response = [ |
||
| 30 | 'status' => false, |
||
| 31 | 'providerResult' => $sf->getMessage(), |
||
| 32 | ]; |
||
| 33 | } |
||
| 34 | |||
| 35 | return $response; |
||
| 36 | } |
||
| 38 |