Skip to content

Commit cd56d1e

Browse files
committed
Tightened notify() conditions when config.notifDisabled ↞ [auto-sync from https://github.com/adamlui/ai-web-extensions/tree/main/chatgpt-infinity]
1 parent 407609e commit cd56d1e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

chatgpt/chatgpt-infinity/chatgpt-infinity.user.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@
199199
// @description:zh-TW 從無所不知的 ChatGPT 生成無窮無盡的答案 (用任何語言!)
200200
// @author Adam Lui
201201
// @namespace https://github.com/adamlui
202-
// @version 2025.5.22
202+
// @version 2025.5.22.1
203203
// @license MIT
204204
// @icon https://assets.chatgptinfinity.com/images/icons/infinity-symbol/circled/with-robot/icon48.png?v=8df6f33
205205
// @icon64 https://assets.chatgptinfinity.com/images/icons/infinity-symbol/circled/with-robot/icon64.png?v=8df6f33
@@ -448,6 +448,9 @@
448448

449449
window.notify = (msg, pos = '', notifDuration = '', shadow = '') => {
450450
if (!styles.toast.node) styles.update({ key: 'toast' })
451+
if (config.notifDisabled
452+
&& !new RegExp(`${app.msgs.menuLabel_show} ${app.msgs.menuLabel_notifs}|🧩`, 'i').test(msg)
453+
) return
451454

452455
// Strip state word to append colored one later
453456
const foundState = toolbarMenu.state.words.find(word => msg.includes(word))

0 commit comments

Comments
 (0)