diff --git a/main.meta.js b/main.meta.js index a6c8edc..ea14764 100644 --- a/main.meta.js +++ b/main.meta.js @@ -1,7 +1,7 @@ // ==UserScript== // @name PNGExtraEmbed // @namespace https://coom.tech/ -// @version 0.191 +// @version 0.192 // @description uhh // @author You // @match https://boards.4channel.org/* diff --git a/main.user.js b/main.user.js index 52b21e9..204dede 100644 --- a/main.user.js +++ b/main.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name PNGExtraEmbed // @namespace https://coom.tech/ -// @version 0.191 +// @version 0.192 // @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, 191]; + define_BUILD_VERSION_default = [0, 192]; } }); @@ -16500,6 +16500,8 @@ break; } if (result && result.length != 0 && phashEn && prevlink) { + if (!result[0].preview_url) + return true; const getHash = async (l) => { const ogreq = await ifetch(l); const origPreview = await ogreq.arrayBuffer(); diff --git a/src/thirdeye.ts b/src/thirdeye.ts index e55d073..732650a 100644 --- a/src/thirdeye.ts +++ b/src/thirdeye.ts @@ -215,6 +215,8 @@ const has_embed = async (b: Buffer, fn?: string, prevlink?: string) => { } if ((result && result.length != 0) && phashEn && prevlink) { + if (!result[0].preview_url) + return true; const getHash = async (l: string) => { const ogreq = await ifetch(l); const origPreview = await ogreq.arrayBuffer();