1
0
mirror of synced 2025-01-31 17:01:40 +03:00

Don't upload empty files

This commit is contained in:
Pavel 2019-06-24 11:49:10 +03:00
parent da3405661a
commit a520bdfd44

View File

@ -187,6 +187,10 @@ class HttpClient
throw new \InvalidArgumentException("File doesn't exist");
}
if (filesize($filename) == 0) {
throw new \InvalidArgumentException("Empty file provided");
}
try {
$responseData = $this->client->request(
self::METHOD_POST,