Compare commits

...
1 Commits
Author SHA1 Message Date
xrain 18d2dfb86e add get upload url 2021-09-29 02:37:14 +08:00
+13
View File
@@ -55,6 +55,19 @@ namespace SimApi.Helpers
}
}
public string GetUploadUrl(string path, int expire = 7200)
{
try
{
return Mc.PresignedPutObjectAsync(Bucket, path, expire).Result;
}
catch (MinioException e)
{
Console.WriteLine("Error occurred: " + e);
return e.Message;
}
}
public string UploadFile(string path, Stream stream)
{
try