From dd898656d0edee1ad1e7e8c89ed1d0761ac454ad Mon Sep 17 00:00:00 2001 From: coomdev Date: Tue, 12 Apr 2022 20:29:05 +0200 Subject: [PATCH] build changes --- main.meta.js | 2 +- main.user.js | 11 ++++------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/main.meta.js b/main.meta.js index 8e652a7..806350e 100644 --- a/main.meta.js +++ b/main.meta.js @@ -1,7 +1,7 @@ // ==UserScript== // @name PNGExtraEmbed // @namespace https://coom.tech/ -// @version 0.177 +// @version 0.182 // @description uhh // @author You // @match https://boards.4channel.org/* diff --git a/main.user.js b/main.user.js index 1e0f1d7..ef1e424 100644 --- a/main.user.js +++ b/main.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name PNGExtraEmbed // @namespace https://coom.tech/ -// @version 0.177 +// @version 0.182 // @description uhh // @author You // @match https://boards.4channel.org/* @@ -81,7 +81,7 @@ var define_BUILD_VERSION_default; var init_define_BUILD_VERSION = __esm({ ""() { - define_BUILD_VERSION_default = [0, 177]; + define_BUILD_VERSION_default = [0, 182]; } }); @@ -20025,15 +20025,12 @@ csettings4 = b; }); var getExt = (fn) => { - const isDum = fn.match(/^[a-z0-9]{6}\./i); const isB64 = fn.match(/^((?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=))?\.(gif|jpe?g|png|webm)/); const isExt = fn.match(/\[.*=(.*)\]/); let ext; let source; try { - if (isDum) { - ext = fn.split(".").slice(0, -1).join("."); - } else if (isB64) { + if (isB64) { ext = atob(isB64[1]); } else if (isExt) { ext = decodeURIComponent(isExt[1]); @@ -22483,7 +22480,7 @@ $$invalidate(3, updating = true); let params = ""; if ($settings.phash) { - params = "?mdist" + $settings.mdist; + params = "?mdist=" + $settings.mdist; } let res = await fetch("https://shoujo.coom.tech/listing/" + boardname + params); $$invalidate(4, threads = await res.json());