Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
goosewobbler committed Oct 9, 2023
1 parent 3b70e31 commit 3ba237b
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/launcher.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import findVersions from 'find-versions';
import { readPackageUp, type NormalizedReadResult } from 'read-pkg-up'
import { readPackageUp, type NormalizedReadResult } from 'read-pkg-up';
import { SevereServiceError } from 'webdriverio';
import { Services, Options, Capabilities } from '@wdio/types';

Expand All @@ -23,10 +23,9 @@ export default class ElectronLaunchService implements Services.ServiceInstance {
: Object.values(capabilities).map((multiremoteOption) => multiremoteOption.capabilities);

const caps = capsList.flatMap((cap) => getElectronCapabilities(cap) as WebDriver.Capabilities[]);
const pkg = (
await readPackageUp({ cwd: this.#projectRoot }) ||
{ packageJson: { dependencies: {}, devDependencies: {} } } as NormalizedReadResult
);
const pkg =
(await readPackageUp({ cwd: this.#projectRoot })) ||
({ packageJson: { dependencies: {}, devDependencies: {} } } as NormalizedReadResult);

const { dependencies, devDependencies } = pkg.packageJson;
const pkgElectronVersion = dependencies?.electron || devDependencies?.electron;
Expand Down

0 comments on commit 3ba237b

Please sign in to comment.