Update channels.js

This commit is contained in:
Aleksandr Statciuk 2023-05-25 19:16:02 +03:00
parent b9bd3ed0bd
commit a4a8c0b688

View file

@ -53,7 +53,7 @@ module.exports = {
scheme: ['https']
})
.custom((value, helper) => {
const ext = path.extname(value)
const ext = path.extname(path.basename(value))
if (!ext || /(\.png|\.jpeg|\.jpg)/i.test(ext)) {
return true
} else {