Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions build.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,11 @@ async function buildFirefoxLibre() {
const manifestPath = path.join(firefoxLibreBuildDir, 'manifest.json');
const manifest = JSON.parse(fs.readFileSync(manifestPath, 'utf8'));

manifest.permissions.push('downloads', 'cookies', 'contextualIdentities');
// 'contextualIdentities' is not requested: Firefox scopes that permission
// to the browser.contextualIdentities namespace, which nothing here calls.
// The container support in background.mjs only reads a tab's
// cookieStoreId and passes it to tabs.create(), which 'cookies' covers.
manifest.permissions.push('downloads', 'cookies');

// remove the userscripts permission
manifest.permissions = manifest.permissions.filter((permission) => permission !== 'userScripts');
Expand Down Expand Up @@ -371,7 +375,8 @@ async function buildFirefoxDist() {
type: 'module',
};

manifest.permissions.push('downloads', 'cookies', 'contextualIdentities');
// see the matching comment in buildFirefoxLibre()
manifest.permissions.push('downloads', 'cookies');

// remove the userscripts permission
manifest.permissions = manifest.permissions.filter((permission) => permission !== 'userScripts');
Expand Down