diff --git a/scripts/chat.js b/scripts/chat.js index 80726a0..12ccb28 100644 --- a/scripts/chat.js +++ b/scripts/chat.js @@ -1,6 +1,6 @@ /** * @name chat.js - * @version 0.1.3 + * @version 0.1.4 * @url https://github.com/lencx/ChatGPT/tree/main/scripts/chat.js */ @@ -25,7 +25,6 @@ function chatInit() { }); document.addEventListener('visibilitychange', focusOnInput); - gpt4Mobile(); autoContinue(); } @@ -117,38 +116,6 @@ function chatInit() { }; } - function gpt4Mobile() { - const originFetch = fetch; - window.fetch = (url, options) => { - return originFetch(url, options).then(async (response) => { - if (url.indexOf('/backend-api/models') === -1) { - return response; - } - const responseClone = response.clone(); - let res = await responseClone.json(); - res.models = res.models.map((m) => { - m.tags = m.tags.filter((t) => { - return t !== 'mobile'; - }); - if (m.slug === 'gpt-4-mobile') { - res.categories.push({ - browsing_model: null, - category: 'gpt_4', - code_interpreter_model: null, - default_model: 'gpt-4-mobile', - human_category_name: 'GPT-4-Mobile', - plugins_model: null, - subscription_level: 'plus', - }); - } - return m; - }); - - return new Response(JSON.stringify(res), response); - }); - }; - } - function autoContinue() { // Create an instance of the observer const observer = new MutationObserver((mutationsList) => { diff --git a/scripts/manifest.json b/scripts/manifest.json index 1a6d3c4..594630b 100644 --- a/scripts/manifest.json +++ b/scripts/manifest.json @@ -6,7 +6,7 @@ "scripts": [ { "name": "chat.js", - "version": "0.1.3" + "version": "0.1.4" }, { "name": "cmd.js",