Skip to content

Commit

Permalink
[CP-3170] Remove redundant vendor id check
Browse files Browse the repository at this point in the history
  • Loading branch information
dkarski committed Oct 16, 2024
1 parent a86b8a7 commit 1a0f7f0
Showing 1 changed file with 3 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,18 +42,13 @@ class MacDeviceFlashService implements IDeviceFlash {
const devices = await this.getDevices()

const device = devices.find((device) => {
return (
device.VendorID?.includes("3310") &&
device.name?.includes("Mudita Harmony (MSC mode)")
)
return device.name?.includes("Mudita Harmony (MSC mode)")
})

if (!device) {
console.error(
`Device with VendorID: 3310 and name: "Mudita Harmony (MSC mode)" not found.`
)
console.error(`Device with Name: "Mudita Harmony (MSC mode)" not found.`)
throw new Error(
`Device with VendorID: 3310 and name: "Mudita Harmony (MSC mode)" not found.`
`Device with Name: "Mudita Harmony (MSC mode)" not found.`
)
}

Expand Down

0 comments on commit 1a0f7f0

Please sign in to comment.