@@ -58,9 +58,9 @@ |
||
58 | 58 | if (0 !== count($this->meta)) { |
59 | 59 | foreach ($this->meta as $key => $value) { |
60 | 60 | if (!is_bool($value)) { |
61 | - $queries['meta_' . $key] = $value; |
|
61 | + $queries['meta_'.$key] = $value; |
|
62 | 62 | } else { |
63 | - $queries['meta_' . $key] = $value ? 'true' : 'false'; |
|
63 | + $queries['meta_'.$key] = $value ? 'true' : 'false'; |
|
64 | 64 | } |
65 | 65 | } |
66 | 66 | } |
@@ -75,7 +75,7 @@ |
||
75 | 75 | } |
76 | 76 | |
77 | 77 | if (!is_string($result)) { |
78 | - throw new \RuntimeException('String expected, but ' . gettype($result) . ' received.'); |
|
78 | + throw new \RuntimeException('String expected, but '.gettype($result).' received.'); |
|
79 | 79 | } |
80 | 80 | |
81 | 81 | return $result; |
@@ -55,9 +55,9 @@ |
||
55 | 55 | if (0 !== count($this->userData)) { |
56 | 56 | foreach ($this->userData as $key => $value) { |
57 | 57 | if (!is_bool($value)) { |
58 | - $queries['userdata-' . $key] = $value; |
|
58 | + $queries['userdata-'.$key] = $value; |
|
59 | 59 | } else { |
60 | - $queries['userdata-' . $key] = $value ? 'true' : 'false'; |
|
60 | + $queries['userdata-'.$key] = $value ? 'true' : 'false'; |
|
61 | 61 | } |
62 | 62 | } |
63 | 63 | } |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | */ |
91 | 91 | public function buildUrl(string $method = '', string $params = '', bool $append = true): string |
92 | 92 | { |
93 | - return $this->baseUrl . 'api/' . $method . ($append ? '?' . $this->buildQs($method, $params) : ''); |
|
93 | + return $this->baseUrl.'api/'.$method.($append ? '?'.$this->buildQs($method, $params) : ''); |
|
94 | 94 | } |
95 | 95 | |
96 | 96 | /** |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | */ |
101 | 101 | public function buildQs(string $method = '', string $params = ''): string |
102 | 102 | { |
103 | - return $params . '&checksum=' . hash($this->hashingAlgorithm, $method . $params . $this->secret); |
|
103 | + return $params.'&checksum='.hash($this->hashingAlgorithm, $method.$params.$this->secret); |
|
104 | 104 | } |
105 | 105 | |
106 | 106 | // URL-Generators |
@@ -93,12 +93,12 @@ discard block |
||
93 | 93 | { |
94 | 94 | // Provide an early error message if configuration is wrong |
95 | 95 | if (is_null($baseUrl) && false === getenv('BBB_SERVER_BASE_URL')) { |
96 | - throw new \RuntimeException('No BBB-Server-Url found! Please provide it either in constructor ' . |
|
96 | + throw new \RuntimeException('No BBB-Server-Url found! Please provide it either in constructor '. |
|
97 | 97 | "(1st argument) or by environment variable 'BBB_SERVER_BASE_URL'!"); |
98 | 98 | } |
99 | 99 | |
100 | 100 | if (is_null($secret) && false === getenv('BBB_SECRET') && false === getenv('BBB_SECURITY_SALT')) { |
101 | - throw new \RuntimeException('No BBB-Secret (or BBB-Salt) found! Please provide it either in constructor ' . |
|
101 | + throw new \RuntimeException('No BBB-Secret (or BBB-Salt) found! Please provide it either in constructor '. |
|
102 | 102 | "(2nd argument) or by environment variable 'BBB_SECRET' (or 'BBB_SECURITY_SALT')!"); |
103 | 103 | } |
104 | 104 | |
@@ -538,7 +538,7 @@ discard block |
||
538 | 538 | $cookieFile = tmpfile(); |
539 | 539 | |
540 | 540 | if (!$ch) { // @phpstan-ignore-line |
541 | - throw new \RuntimeException('Unhandled curl error: ' . curl_error($ch)); |
|
541 | + throw new \RuntimeException('Unhandled curl error: '.curl_error($ch)); |
|
542 | 542 | } |
543 | 543 | |
544 | 544 | // JSESSIONID |
@@ -559,7 +559,7 @@ discard block |
||
559 | 559 | |
560 | 560 | // Initialise headers array with mandatory Content-type |
561 | 561 | $headers = [ |
562 | - 'Content-type: ' . $contentType, |
|
562 | + 'Content-type: '.$contentType, |
|
563 | 563 | ]; |
564 | 564 | |
565 | 565 | // PAYLOAD |
@@ -569,7 +569,7 @@ discard block |
||
569 | 569 | curl_setopt($ch, CURLOPT_POST, 1); |
570 | 570 | curl_setopt($ch, CURLOPT_POSTFIELDS, $payload); |
571 | 571 | // Add Content-length header if payload is present |
572 | - $headers[] = 'Content-length: ' . strlen($payload); |
|
572 | + $headers[] = 'Content-length: '.strlen($payload); |
|
573 | 573 | } |
574 | 574 | |
575 | 575 | // Set HTTP headers |
@@ -592,7 +592,7 @@ discard block |
||
592 | 592 | |
593 | 593 | // ANALYSE |
594 | 594 | if (false === $data) { |
595 | - throw new \RuntimeException('Unhandled curl error: ' . curl_error($ch)); |
|
595 | + throw new \RuntimeException('Unhandled curl error: '.curl_error($ch)); |
|
596 | 596 | } |
597 | 597 | |
598 | 598 | if (is_bool($data)) { |
@@ -600,7 +600,7 @@ discard block |
||
600 | 600 | } |
601 | 601 | |
602 | 602 | if ($httpCode < 200 || $httpCode >= 300) { |
603 | - throw new BadResponseException('Bad response, HTTP code: ' . $httpCode . ', url: ' . $url); |
|
603 | + throw new BadResponseException('Bad response, HTTP code: '.$httpCode.', url: '.$url); |
|
604 | 604 | } |
605 | 605 | |
606 | 606 | // CLOSE AND UNSET |