Fix message lookup in details popup

This commit is contained in:
Jordan Wages 2025-07-05 05:07:48 -05:00
commit 6b741595cc
2 changed files with 3 additions and 3 deletions

View file

@ -413,7 +413,7 @@ async function clearCacheForMessages(idsInput) {
}
} else if (msg?.type === "sortana:clearCacheForDisplayed") {
try {
const tabs = await browser.tabs.query({ active: true, currentWindow: true });
const tabs = await browser.tabs.query({ active: true, lastFocusedWindow: true });
const tabId = tabs[0]?.id;
const msgs = tabId ? await browser.messageDisplay.getDisplayedMessages(tabId) : [];
const ids = msgs.map(m => m.id);