mirror of
https://github.com/D4M13N-D3V/comissions-app-core-api.git
synced 2025-03-14 10:04:55 +00:00
fix: adde dnull check
This commit is contained in:
parent
8f50f3b6c3
commit
202ee68e4b
@ -17,6 +17,10 @@ namespace comissions.app.api.Services.Storage
|
||||
|
||||
public async Task<string> UploadImageAsync(Stream fileStream, string fileName)
|
||||
{
|
||||
if(fileStream== null)
|
||||
{
|
||||
throw new System.ArgumentNullException(nameof(fileStream));
|
||||
}
|
||||
using var content = new MultipartFormDataContent();
|
||||
content.Add(new StringContent(ApiKey), "key");
|
||||
content.Add(new StreamContent(fileStream), "source", fileName);
|
||||
|
Loading…
x
Reference in New Issue
Block a user