fix: Resolved the issue of duplicate display of supported file types during text file upload (#2241)

Co-authored-by: hbc <hbc@hbc-iMac.local>
This commit is contained in:
Moonlit 2024-01-26 19:44:49 +08:00 committed by GitHub
parent 8cb62ef31a
commit d8f8afcbd0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -72,6 +72,8 @@ const FileUploader = ({
return item
})
res = res.map(item => item.toLowerCase())
res = res.filter((item, index, self) => self.indexOf(item) === index)
return res.map(item => item.toUpperCase()).join(language !== LanguagesSupportedUnderscore[1] ? ', ' : '、 ')
})()