@@ -215,10 +215,13 @@ public function update($id, array $params)
215215 ];
216216 $ params = $ this ->sanitizeParams ($ defaults , $ params );
217217
218- return $ this ->put (
218+ $ this ->lastResponse = $ this ->getHttpClient ()->request (HttpFactory::makeXmlRequest (
219+ 'PUT ' ,
219220 '/projects/ ' . urlencode (strval ($ id )) . '.xml ' ,
220221 XmlSerializer::createFromArray (['project ' => $ params ])->getEncoded ()
221- );
222+ ));
223+
224+ return $ this ->lastResponse ->getContent ();
222225 }
223226
224227 /**
@@ -242,10 +245,11 @@ final public function close($projectIdentifier): bool
242245 ));
243246 }
244247
245- $ this ->put (
248+ $ this ->lastResponse = $ this ->getHttpClient ()->request (HttpFactory::makeXmlRequest (
249+ 'PUT ' ,
246250 '/projects/ ' . strval ($ projectIdentifier ) . '/close.xml ' ,
247251 ''
248- );
252+ )) ;
249253
250254 $ lastResponse = $ this ->getLastResponse ();
251255
@@ -277,10 +281,11 @@ final public function reopen($projectIdentifier): bool
277281 ));
278282 }
279283
280- $ this ->put (
284+ $ this ->lastResponse = $ this ->getHttpClient ()->request (HttpFactory::makeXmlRequest (
285+ 'PUT ' ,
281286 '/projects/ ' . strval ($ projectIdentifier ) . '/reopen.xml ' ,
282287 ''
283- );
288+ )) ;
284289
285290 $ lastResponse = $ this ->getLastResponse ();
286291
@@ -312,10 +317,11 @@ final public function archive($projectIdentifier): bool
312317 ));
313318 }
314319
315- $ this ->put (
320+ $ this ->lastResponse = $ this ->getHttpClient ()->request (HttpFactory::makeXmlRequest (
321+ 'PUT ' ,
316322 '/projects/ ' . strval ($ projectIdentifier ) . '/archive.xml ' ,
317323 ''
318- );
324+ )) ;
319325
320326 $ lastResponse = $ this ->getLastResponse ();
321327
@@ -347,10 +353,11 @@ final public function unarchive($projectIdentifier): bool
347353 ));
348354 }
349355
350- $ this ->put (
356+ $ this ->lastResponse = $ this ->getHttpClient ()->request (HttpFactory::makeXmlRequest (
357+ 'PUT ' ,
351358 '/projects/ ' . strval ($ projectIdentifier ) . '/unarchive.xml ' ,
352359 ''
353- );
360+ )) ;
354361
355362 $ lastResponse = $ this ->getLastResponse ();
356363
0 commit comments