@@ -25,7 +25,7 @@ |
||
| 25 | 25 | throw LogicException::only10CustomFieldsAreAllowed(); |
| 26 | 26 | } |
| 27 | 27 | |
| 28 | - $this->customFields[$this->getCustomFieldPrefix().'_custom_field'.(count($this->customFields) + 1)] = $value; |
|
| 28 | + $this->customFields[$this->getCustomFieldPrefix() . '_custom_field' . (count($this->customFields) + 1)] = $value; |
|
| 29 | 29 | } |
| 30 | 30 | |
| 31 | 31 | public function getCustomFields() |
@@ -18,17 +18,17 @@ |
||
| 18 | 18 | |
| 19 | 19 | public static function requiredFieldDoesntExist($requiredField): self |
| 20 | 20 | { |
| 21 | - return new static(self::mapFieldNames($requiredField).' is a mandatory field and is not set.'); |
|
| 21 | + return new static(self::mapFieldNames($requiredField) . ' is a mandatory field and is not set.'); |
|
| 22 | 22 | } |
| 23 | 23 | |
| 24 | 24 | public static function pendingImplementation($message): self |
| 25 | 25 | { |
| 26 | - return new static('This section still needs to be implemented for '.$message); |
|
| 26 | + return new static('This section still needs to be implemented for ' . $message); |
|
| 27 | 27 | } |
| 28 | 28 | |
| 29 | 29 | public static function methodCallNotSupported($message): self |
| 30 | 30 | { |
| 31 | - return new static('This method call is not supported for'.$message); |
|
| 31 | + return new static('This method call is not supported for' . $message); |
|
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | private static function mapFieldNames($field) |
@@ -5,7 +5,7 @@ |
||
| 5 | 5 | if (!function_exists('clear_array')) { |
| 6 | 6 | function clear_array($data) |
| 7 | 7 | { |
| 8 | - return array_filter($data, function ($item) { |
|
| 8 | + return array_filter($data, function($item) { |
|
| 9 | 9 | if ($item === null) { |
| 10 | 10 | return false; |
| 11 | 11 | } |
@@ -137,7 +137,7 @@ |
||
| 137 | 137 | */ |
| 138 | 138 | private function sendRequest($uri, $data) |
| 139 | 139 | { |
| 140 | - $url = $this->getEndpointURL().$uri; |
|
| 140 | + $url = $this->getEndpointURL() . $uri; |
|
| 141 | 141 | |
| 142 | 142 | $params = [ |
| 143 | 143 | 'http' => [ |
@@ -16,7 +16,7 @@ |
||
| 16 | 16 | */ |
| 17 | 17 | public static function clearArray($data) |
| 18 | 18 | { |
| 19 | - return array_filter($data, function ($item) { |
|
| 19 | + return array_filter($data, function($item) { |
|
| 20 | 20 | if ($item === null) { |
| 21 | 21 | return false; |
| 22 | 22 | } |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | $data = ''; |
| 86 | 86 | for ($i = 0; $i < strlen($txtsec); $i++) { |
| 87 | 87 | $mybyte = decbin(ord($txtsec[$i])); |
| 88 | - $MyBitSec = substr('00000000', 0, 8 - strlen($mybyte)).$mybyte; |
|
| 88 | + $MyBitSec = substr('00000000', 0, 8 - strlen($mybyte)) . $mybyte; |
|
| 89 | 89 | $data .= $MyBitSec; |
| 90 | 90 | } |
| 91 | 91 | |
@@ -103,7 +103,7 @@ discard block |
||
| 103 | 103 | for ($i = 0; $i < strlen($binsec); $i += 8) { |
| 104 | 104 | $bin = substr($binsec, $i, 8); |
| 105 | 105 | $hex = dechex(bindec($bin)); |
| 106 | - $hex = substr('00', 0, 2 - strlen($hex)).$hex; |
|
| 106 | + $hex = substr('00', 0, 2 - strlen($hex)) . $hex; |
|
| 107 | 107 | $data .= $hex; |
| 108 | 108 | } |
| 109 | 109 | |
@@ -119,8 +119,8 @@ discard block |
||
| 119 | 119 | { |
| 120 | 120 | $data = ''; |
| 121 | 121 | for ($i = 0; $i < strlen($hexsec); $i += 2) { |
| 122 | - $byte = decbin(hexdec($hexsec[$i].$hexsec[$i + 1])); |
|
| 123 | - $bitSec = substr('00000000', 0, 8 - strlen($byte)).$byte; |
|
| 122 | + $byte = decbin(hexdec($hexsec[$i] . $hexsec[$i + 1])); |
|
| 123 | + $bitSec = substr('00000000', 0, 8 - strlen($byte)) . $byte; |
|
| 124 | 124 | $data .= $bitSec; |
| 125 | 125 | } |
| 126 | 126 | |