You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@answer.apache.org by li...@apache.org on 2024/12/09 03:52:47 UTC

(incubator-answer) 22/38: feat(upload): add support for file attachments and enhance image upload

This is an automated email from the ASF dual-hosted git repository.

linkinstar pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-answer.git

commit aac2370fe8948acc51bb1099e9e0231c7ecde2a4
Author: LinkinStars <li...@foxmail.com>
AuthorDate: Thu Nov 21 15:53:58 2024 +0800

    feat(upload): add support for file attachments and enhance image upload
---
 internal/schema/siteinfo_schema.go | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/internal/schema/siteinfo_schema.go b/internal/schema/siteinfo_schema.go
index 814465d9..fee6b8cb 100644
--- a/internal/schema/siteinfo_schema.go
+++ b/internal/schema/siteinfo_schema.go
@@ -79,8 +79,8 @@ type SiteWriteReq struct {
 	MaxImageSize                   int             `validate:"omitempty,gt=0" json:"max_image_size"`
 	MaxAttachmentSize              int             `validate:"omitempty,gt=0" json:"max_attachment_size"`
 	MaxImageMegapixel              int             `validate:"omitempty,gt=0" json:"max_image_megapixel"`
-	AuthorizedImageExtensions      []string        `validate:"omitempty,dive,gt=0,lte=128" json:"authorized_image_extensions"`
-	AuthorizedAttachmentExtensions []string        `validate:"omitempty,dive,gt=0,lte=128" json:"authorized_attachment_extensions"`
+	AuthorizedImageExtensions      []string        `validate:"omitempty" json:"authorized_image_extensions"`
+	AuthorizedAttachmentExtensions []string        `validate:"omitempty" json:"authorized_attachment_extensions"`
 	UserID                         string          `json:"-"`
 }