From 5caee1fd97d7324a6b0daf53431ec1939f1f9c38 Mon Sep 17 00:00:00 2001 From: teddit Date: Wed, 2 Dec 2020 21:06:28 +0100 Subject: [PATCH] rm redundant lines --- views/includes/head.pug | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/views/includes/head.pug b/views/includes/head.pug index 29b7af2..e10f553 100644 --- a/views/includes/head.pug +++ b/views/includes/head.pug @@ -81,9 +81,7 @@ meta(name="viewport", content="width=device-width, initial-scale=1.0") let file_ext = getFileExtension(url) if(image_exts.includes(file_ext)) url = url.replace(`${u.host}/`, 'teddit.net/pics/w:null_') - if(video_exts.includes(file_ext)) - url = url.replace(u.host, 'teddit.net/vids') + '.mp4' - if(!video_exts.includes(file_ext) && !image_exts.includes(file_ext)) + if(video_exts.includes(file_ext) || !image_exts.includes(file_ext)) url = url.replace(u.host, 'teddit.net/vids') + '.mp4' }