Commit 2c0e6ca
authored
handle importXmlInternalError gracefully in RO.php
parseResponse() was throwing "Cannot access offset of type string on string" from line 1301 when response from FlexiBee came with following data:
```
["@Version" => "1.0", "success" => "false", "stats" => ["created" => "0", "updated" => "1", "deleted" => "0", "skipped" => "0", "failed" => "0"], "results" => [["errors" => [["message" => "Interní chyba aplikace.", "messageCode" => "importXmlInternalError"]]]]]
```
That made it hard to diagnose problems, because it stripped out relevant information from FlexiBee response. This commit adds fallback for this case when message is not found where expected.1 parent e183c45 commit 2c0e6ca
1 file changed
+8
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1298 | 1298 | | |
1299 | 1299 | | |
1300 | 1300 | | |
1301 | | - | |
| 1301 | + | |
| 1302 | + | |
| 1303 | + | |
| 1304 | + | |
| 1305 | + | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
1302 | 1309 | | |
1303 | 1310 | | |
1304 | 1311 | | |
| |||
0 commit comments