Explorar o código

Fix missing response

Joachim M. Giæver %!s(int64=2) %!d(string=hai) anos
pai
achega
dd909d9006
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      src/Client.php

+ 2 - 2
src/Client.php

@@ -120,9 +120,9 @@ final class Client {
                 }
                 $content = json_encode($content);
             } else
-                $content = $e->getMessage();
+                $content = $ret->getContent(false);
 
-            throw new \InvalidArgumentException($content, $e->getCode(), $e);
+            throw new \InvalidArgumentException($content ? $content : $e->getMessage(), $e->getCode(), $e);
         }
 
         return false;