Skip to content

Commit

Permalink
Lint + tests fix
Browse files Browse the repository at this point in the history
  • Loading branch information
cezaraugusto committed Sep 3, 2024
1 parent efc286d commit df46445
Show file tree
Hide file tree
Showing 4 changed files with 128 additions and 144 deletions.
1 change: 0 additions & 1 deletion programs/develop/commands/commands-lib/extract-from-zip.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import fs from 'fs/promises'
import path from 'path'
import axios from 'axios'
import AdmZip from 'adm-zip'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,8 @@ describe('getManifestFieldsData', () => {
'images/my-image.png',
'script.js',
'styles.css'
]
],
locales: []
})
})

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type webpack from 'webpack'
import {Compiler} from 'webpack'
import {
type FilepathList,
type PluginInterface,
Expand All @@ -21,15 +21,15 @@ export class AddPublicPathForMainWorld {
this.excludeList = options.excludeList || {}
}

public apply(): void {
public apply(_compiler: Compiler): void {
const manifest: Manifest = require(this.manifestPath)
if (
manifest.content_scripts?.some(
// @ts-expect-error - TS doesn't know about content_scripts
(cs) => cs.world && cs.world.toLowerCase() === 'main'
)
) {
if (!CHROMIUM_BASED_BROWSERS.includes(this.browser) && manifest.key) {
if (CHROMIUM_BASED_BROWSERS.includes(this.browser) && !manifest.key) {
console.error(messages.noExtensionIdError(manifest.name || ''))
process.exit(1)
}
Expand Down
Loading

0 comments on commit df46445

Please sign in to comment.