优化文件存储

This commit is contained in:
不做码农
2022-03-10 21:39:46 +08:00
parent 3555833ae7
commit eb32117b8c
9 changed files with 57 additions and 108 deletions

View File

@@ -21,7 +21,7 @@ namespace ZR.Common
/// <param name="bucketName">存储桶 如果为空默认取配置文件</param>
public static System.Net.HttpStatusCode PutObjectFromFile(Stream filestreams, string dirPath, string bucketName = "")
{
OssClient client = new OssClient(endpoint, accessKeyId, accessKeySecret);
OssClient client = new(endpoint, accessKeyId, accessKeySecret);
if (string.IsNullOrEmpty(bucketName)) { bucketName = bucketName1; }
try
{