From 8507032845a99351d25d252951e699a3b817704d Mon Sep 17 00:00:00 2001 From: Hamza-Ayed Date: Sun, 17 May 2026 21:47:20 +0300 Subject: [PATCH] Auto-deploy: 2026-05-17 21:47:20 --- content.js | 10 +++++++++- popup.js | 10 ++++++++-- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/content.js b/content.js index 7b87cec..c6854a4 100644 --- a/content.js +++ b/content.js @@ -931,7 +931,15 @@ Brief honest assessment of this opportunity for my profile` function getSettings() { return new Promise(resolve => { - chrome.storage.sync.get(['apiKey', 'userProfile', 'language'], resolve); + chrome.storage.sync.get(['apiKey', 'userProfile', 'language'], (data) => { + if (data.userProfile && (data.userProfile.includes('hamzaayed@intaleqapp.com') || data.userProfile.includes('hamzaayedflutter@gmail.com'))) { + data.userProfile = data.userProfile + .replace(/hamzaayed@intaleqapp\.com/g, 'hamzaayed@tripz-egypt.com') + .replace(/hamzaayedflutter@gmail\.com/g, 'hamzaayed@tripz-egypt.com'); + chrome.storage.sync.set({ userProfile: data.userProfile }); + } + resolve(data); + }); }); } diff --git a/popup.js b/popup.js index ea8ba5a..e1268e5 100644 --- a/popup.js +++ b/popup.js @@ -39,8 +39,14 @@ function loadSettings() { document.getElementById('api-key-input').value = data.apiKey; setKeyStatus('ok'); } - document.getElementById('profile-textarea').value = - data.userProfile || DEFAULT_PROFILE; + let profile = data.userProfile || DEFAULT_PROFILE; + if (profile.includes('hamzaayed@intaleqapp.com') || profile.includes('hamzaayedflutter@gmail.com')) { + profile = profile + .replace(/hamzaayed@intaleqapp\.com/g, 'hamzaayed@tripz-egypt.com') + .replace(/hamzaayedflutter@gmail\.com/g, 'hamzaayed@tripz-egypt.com'); + chrome.storage.sync.set({ userProfile: profile }); + } + document.getElementById('profile-textarea').value = profile; document.getElementById('lang-select').value = data.language || 'auto'; });