Skip to content

Commit

Permalink
fix phpstan errors caused by type hint changes
Browse files Browse the repository at this point in the history
  • Loading branch information
vredeling committed May 21, 2022
1 parent e2addcd commit 82ccfdf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Strava/API/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ public function createActivity(string $name, string $type, string $start_date_lo
* Upload an activity
*
* @link https://strava.github.io/api/v3/uploads/#post-file
* @param $file
* @param string $file Path to file
* @param string|null $activity_type
* @param string|null $name
* @param string|null $description
Expand All @@ -426,7 +426,7 @@ public function createActivity(string $name, string $type, string $start_date_lo
* @return array
* @throws Exception
*/
public function uploadActivity($file, string $activity_type = null, string $name = null, string $description = null, int $private = null, int $trainer = null, int $commute = null, string $data_type = null, string $external_id = null): array
public function uploadActivity(string $file, string $activity_type = null, string $name = null, string $description = null, int $private = null, int $trainer = null, int $commute = null, string $data_type = null, string $external_id = null): array
{
try {
return $this->service->uploadActivity($file, $activity_type, $name, $description, $private, $trainer, $commute, $data_type, $external_id);
Expand Down
2 changes: 1 addition & 1 deletion src/Strava/API/Service/REST.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ protected function getToken()
protected function getResult($response)
{
// Workaround for export methods getRouteAsGPX, getRouteAsTCX:
// @phpstan-ignore-next-line
if (is_string($response)) {
// @phpstan-ignore-next-line
return $response;
}

Expand Down

0 comments on commit 82ccfdf

Please sign in to comment.