@@ -120,6 +120,7 @@ protected function response($response) {
120120 * @return object Preprocessed structured object.
121121 */
122122 public function get ($ path , Array $ path_args = [], Array $ data = []) {
123+ $ this ->setHTTPClient ();
123124 parent ::get ($ path , $ path_args , $ data );
124125 $ this ->setHeaders (
125126 [
@@ -139,6 +140,7 @@ public function get($path, Array $path_args = [], Array $data = []) {
139140 * @return object Preprocessed structured object and returns 204 No Content on success, with no response body.
140141 */
141142 public function delete ($ path , Array $ path_args = [], Array $ data = []) {
143+ $ this ->setHTTPClient ();
142144 parent ::delete ($ path , $ path_args , $ data );
143145 $ this ->setHeaders (
144146 [
@@ -167,6 +169,7 @@ public function delete($path, Array $path_args = [], Array $data = []) {
167169 * @return object Preprocessed structured object.
168170 */
169171 public function post ($ path , Array $ path_args , Array $ data = []) {
172+ $ this ->setHTTPClient ();
170173 parent ::post ($ path , $ path_args , $ data );
171174
172175 // JSON string to be posted to PublisherAPI instead of article.json file.
@@ -218,8 +221,8 @@ public function post($path, Array $path_args, Array $data = []) {
218221 $ info ['contents ' ]
219222 );
220223 }
221-
222- if (!empty ($ multiparts )) {
224+
225+ if (!empty ($ multiparts )) {
223226 // Set content type and boundary token.
224227 $ content_type = sprintf ('multipart/form-data; boundary=%s ' , $ this ->boundary );
225228
0 commit comments