for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace Nelexa\GPlay\Scraper;
use Nelexa\GPlay\Http\ResponseHandlerInterface;
use Psr\Http\Message\RequestInterface;
use Psr\Http\Message\ResponseInterface;
/**
* @internal
*/
class SuggestScraper implements ResponseHandlerInterface
{
* @param RequestInterface $request
* @param ResponseInterface $response
* @return mixed
public function __invoke(RequestInterface $request, ResponseInterface $response)
$json = \GuzzleHttp\json_decode($response->getBody()->getContents(), true);
return array_map(static function (array $v) {
return $v['s'];
}, $json);
}