From 3ba237b0eb9bee232e33b9e7f41e05fb97da39fa Mon Sep 17 00:00:00 2001 From: Sam Maister Date: Mon, 9 Oct 2023 14:13:51 +0100 Subject: [PATCH] formatting --- src/launcher.ts | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/launcher.ts b/src/launcher.ts index 757d6974f..fd2ec9f50 100644 --- a/src/launcher.ts +++ b/src/launcher.ts @@ -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'; @@ -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;