modules: send_file add file type classes

This commit is contained in:
Kay Marquardt (Gnadelwartz) 2021-01-05 22:33:44 +01:00
parent dd19f0f34e
commit 126f61f00c

View File

@ -227,28 +227,28 @@ upload_file(){
[ -z "${ext}" ] && ext="${file##*.}" [ -z "${ext}" ] && ext="${file##*.}"
case "${ext}" in case "${ext}" in
mp3|flac) audio|mp3|flac)
CUR_URL="${AUDIO_URL}" CUR_URL="${AUDIO_URL}"
WHAT="audio" WHAT="audio"
STATUS="upload_audio" STATUS="upload_audio"
;; ;;
png|jpg|jpeg|gif|pic) photo|png|jpg|jpeg|gif|pic)
CUR_URL="${PHO_URL}" CUR_URL="${PHO_URL}"
WHAT="photo" WHAT="photo"
STATUS="upload_photo" STATUS="upload_photo"
;; ;;
webp) sticker|webp)
CUR_URL="${STICKER_URL}" CUR_URL="${STICKER_URL}"
WHAT="sticker" WHAT="sticker"
STATUS="upload_photo" STATUS="upload_photo"
;; ;;
mp4) video|mp4)
CUR_URL="${VIDEO_URL}" CUR_URL="${VIDEO_URL}"
WHAT="video" WHAT="video"
STATUS="upload_video" STATUS="upload_video"
;; ;;
ogg) voice|ogg)
CUR_URL="${VOICE_URL}" CUR_URL="${VOICE_URL}"
WHAT="voice" WHAT="voice"
STATUS="upload_audio" STATUS="upload_audio"