Exemplo n.º 1
0
 function get($path, array $query = [])
 {
     $tmp = FileSystem::join(static::API_BASE_URI, $path);
     \ksort($query);
     $http_build_query = \http_build_query($query);
     $url = "{$tmp}?{$http_build_query}";
     $response = $this->containerd->get($url);
     if ($response) {
         return $response;
     }
     $response = parent::get($path, $query);
     if ($response->isSuccess()) {
         $this->containerd->set($url, $response);
     }
     return $response;
 }