File tree Expand file tree Collapse file tree 3 files changed +12
-10
lines changed Expand file tree Collapse file tree 3 files changed +12
-10
lines changed Original file line number Diff line number Diff line change 3636 - name : Install dependencies
3737 run : composer update --${{ matrix.stability }} --prefer-dist --no-interaction --no-suggest
3838
39+ - name : PHP Security Checker
40+ uses : symfonycorp/security-checker-action@v2
41+ if : ${{ matrix.stability == 'prefer-stable' }}
42+
3943 - name : Execute tests
4044 run : vendor/bin/phpunit --coverage-clover=coverage.clover --verbose
4145
4246 - name : Upload Code Coverage
43- run : wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover coverage.clover
47+ run : wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover coverage.clover
Original file line number Diff line number Diff line change @@ -224,12 +224,10 @@ public function buildAuth()
224224 */
225225 public function buildOptions (array $ options = [])
226226 {
227- return array_merge_recursive (
228- $ options ,
229- [
230- 'headers ' => $ this ->getHeaders (),
231- ]
232- );
227+ return [
228+ 'body ' => json_encode ($ options ?? []),
229+ 'headers ' => $ this ->getHeaders (),
230+ ];
233231 }
234232
235233 /**
@@ -340,7 +338,7 @@ public function getPassword()
340338 *
341339 * @return string
342340 */
343- public function getUrl ($ path = null )
341+ public function getUrl ($ path = '' )
344342 {
345343 return $ this ->url . '/v4_6_release/apis/3.0/ ' . ltrim ($ path , '/ ' );
346344 }
@@ -395,7 +393,7 @@ protected function isCollection(array $array)
395393 */
396394 protected function isLastPage (ResponseInterface $ response )
397395 {
398- return !(bool )preg_match ('/rel="last"$/u ' , $ response ->getHeader ('Link ' )[0 ] ?? null );
396+ return !(bool )preg_match ('/rel="last"$/u ' , $ response ->getHeader ('Link ' )[0 ] ?? '' );
399397 }
400398
401399 /**
Original file line number Diff line number Diff line change @@ -294,7 +294,7 @@ public function it_builds_the_expected_options_array()
294294 $ this ->client ->setIntegrator ($ username );
295295
296296 $ options = [
297- 'extra ' => ' option ' ,
297+ 'body ' => json_encode ([ ' extra ' => ' option ']) ,
298298 'headers ' => [
299299 'added ' => 'header ' ,
300300 'Accept ' => 'application/vnd.connectwise.com+json; version=2019.5 ' ,
You can’t perform that action at this time.
0 commit comments