We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 01b1933 commit 9663c02Copy full SHA for 9663c02
src/IBS/Response.php
@@ -97,7 +97,12 @@ public function getRequestURL()
97
*/
98
public function getCode()
99
{
100
- return ($this->hash["code"]) ? intval($this->hash["code"]) : 200;
+ foreach (["code", "product_0_code"] as $key) {
101
+ if (isset($this->hash[$key])) {
102
+ return intval($this->hash[$key]);
103
+ }
104
105
+ return 200; // default code
106
}
107
108
/**
@@ -115,7 +120,7 @@ public function getStatus()
115
120
116
121
public function getDescription()
117
122
118
- return $this->hash["message"] ?? "Command completed successfully";
123
+ return $this->hash["message"] ?? $this->hash["product_0_message"] ?? "Command completed successfully";
119
124
125
126
0 commit comments