From 0f36d2a3d26374ac25e144d407b9ccd912a0cba4 Mon Sep 17 00:00:00 2001 From: buzz-lightsnack-2007 <73412182+buzz-lightsnack-2007@users.noreply.github.com> Date: Sat, 11 May 2024 18:43:56 +0800 Subject: [PATCH] use update necessity as a factor when determining the need for re-analysis --- scripts/data/product.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/data/product.js b/scripts/data/product.js index 37a80da..210abc4 100644 --- a/scripts/data/product.js +++ b/scripts/data/product.js @@ -67,7 +67,7 @@ export default class product { async analyze(options = {}) { // Stop when the data is already analyzed. - if (((this.analysis && this.analysis != undefined) ? !((typeof this.analysis).includes(`obj`) && !Array.isArray(this.analysis)) : true) || ((options && (typeof options).includes(`obj`)) ? options[`override`] : false)) { + if (((this.analysis && this.analysis != undefined) ? !((typeof this.analysis).includes(`obj`) && !Array.isArray(this.analysis)) : true) || this.status[`update`] || ((options && (typeof options).includes(`obj`)) ? options[`override`] : false)) { const gemini = (await import(chrome.runtime.getURL("scripts/AI/gemini.js"))).default; let analyzer = new gemini (await global.read([`settings`,`analysis`,`api`,`key`]), `gemini-pro`);