pcloud-sdk-php icon indicating copy to clipboard operation
pcloud-sdk-php copied to clipboard

On delete file the response is bool instead of defined stdClass

Open hashdefault opened this issue 1 year ago • 0 comments

pCloud\Sdk\File::delete(): Return value must be of type stdClass, bool returned

Method: delete Class: pCloud\Sdk\File

public function delete(int $fileId): stdClass
{
	$response = $this->request->get("deletefile", array("fileid" => $fileId));

	return property_exists($response, 'metadata') ? $response->metadata->isdeleted : $response;
}

hashdefault avatar Sep 05 '25 19:09 hashdefault