summaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2023-03-19 20:58:43 +0100
committerGitHub <noreply@github.com>2023-03-19 20:58:43 +0100
commitaf3711100a7dc73e8c2482667bbccdcd049e25e0 (patch)
treecd1169fa86a8379b7858ec2fa9c040d94505f52c /modules
parentSort Python package descriptors by version to mimic PyPI format (#23550) (diff)
downloadforgejo-af3711100a7dc73e8c2482667bbccdcd049e25e0.tar.xz
forgejo-af3711100a7dc73e8c2482667bbccdcd049e25e0.zip
Add `.patch` to `attachment.ALLOWED_TYPES` (#23580)
Diffstat (limited to 'modules')
-rw-r--r--modules/setting/attachment.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/setting/attachment.go b/modules/setting/attachment.go
index 8b6eb9fd7a..4d4b8e3b02 100644
--- a/modules/setting/attachment.go
+++ b/modules/setting/attachment.go
@@ -26,7 +26,7 @@ func loadAttachmentFrom(rootCfg ConfigProvider) {
Attachment.Storage = getStorage(rootCfg, "attachments", storageType, sec)
- Attachment.AllowedTypes = sec.Key("ALLOWED_TYPES").MustString(".csv,.docx,.fodg,.fodp,.fods,.fodt,.gif,.gz,.jpeg,.jpg,.log,.md,.mov,.mp4,.odf,.odg,.odp,.ods,.odt,.pdf,.png,.pptx,.svg,.tgz,.txt,.webm,.xls,.xlsx,.zip")
+ Attachment.AllowedTypes = sec.Key("ALLOWED_TYPES").MustString(".csv,.docx,.fodg,.fodp,.fods,.fodt,.gif,.gz,.jpeg,.jpg,.log,.md,.mov,.mp4,.odf,.odg,.odp,.ods,.odt,.patch,.pdf,.png,.pptx,.svg,.tgz,.txt,.webm,.xls,.xlsx,.zip")
Attachment.MaxSize = sec.Key("MAX_SIZE").MustInt64(4)
Attachment.MaxFiles = sec.Key("MAX_FILES").MustInt(5)
Attachment.Enabled = sec.Key("ENABLED").MustBool(true)