Update to laravel 7

This commit is contained in:
KodeStar
2022-03-10 11:54:29 +00:00
parent 61a5a1a8b0
commit f9a19fce91
7170 changed files with 274189 additions and 283773 deletions

View File

@@ -61,6 +61,21 @@ class Search extends AbstractApi
return $this->get('/search/code', ['q' => $q, 'sort' => $sort, 'order' => $order]);
}
/**
* Search code by filter (q), but will return additional data to highlight
* the matched results.
*
* @link https://docs.github.com/en/rest/reference/search#text-match-metadata
*
* @return array list of code found
*/
public function codeWithMatch(string $q, string $sort = 'updated', string $order = 'desc'): array
{
$this->acceptHeaderValue = 'application/vnd.github.v3.text-match+json';
return $this->code($q, $sort, $order);
}
/**
* Search users by filter (q).
*
@@ -90,14 +105,14 @@ class Search extends AbstractApi
*/
public function commits($q, $sort = null, $order = 'desc')
{
//This api is in preview mode, so set the correct accept-header
// This api is in preview mode, so set the correct accept-header
$this->acceptHeaderValue = 'application/vnd.github.cloak-preview';
return $this->get('/search/commits', ['q' => $q, 'sort' => $sort, 'order' => $order]);
}
/**
* Search commits by filter (q).
* Search topics by filter (q).
*
* @link https://developer.github.com/v3/search/#search-topics
*
@@ -107,7 +122,7 @@ class Search extends AbstractApi
*/
public function topics($q)
{
//This api is in preview mode, so set the correct accept-header
// This api is in preview mode, so set the correct accept-header
$this->acceptHeaderValue = 'application/vnd.github.mercy-preview+json';
return $this->get('/search/topics', ['q' => $q]);