fix: align backend APIs and upload flow
This commit is contained in:
@@ -12,9 +12,9 @@ namespace FileService.Domain.ValueObjects
|
||||
|
||||
public FileName(string value)
|
||||
{
|
||||
if(value.Length > 20)
|
||||
if (string.IsNullOrWhiteSpace(value) || value.Length > 255)
|
||||
{
|
||||
throw new ArgumentException("文件名超出长度");
|
||||
throw new ArgumentException("文件名不能为空且不能超过 255 个字符");
|
||||
}
|
||||
|
||||
Value = value;
|
||||
|
||||
Reference in New Issue
Block a user