@@ -72,9 +72,9 @@ async function setWindowsUserLegacyProfile(userProfile: RecursivePartial<Setting
7272 const keyPath = `HKCU\\SOFTWARE\\Rancher Desktop\\Profile\\${ registryType } ` ;
7373
7474 await childProcess . spawnFile ( 'reg.exe' , [ 'DELETE' , keyPath , '/f' ] , { stdio : 'pipe' } ) ;
75- } catch ( ex : any ) {
76- if ( ! / u n a b l e t o f i n d / . test ( Object ( ex ) . stderr ?? '' ) ) {
77- throw new Error ( `Error trying to delete a user registry hive: ${ ex } ` ) ;
75+ } catch ( cause : any ) {
76+ if ( ! / u n a b l e t o f i n d / . test ( Object ( cause ) . stderr ?? '' ) ) {
77+ throw new Error ( `Error trying to delete a user registry hive: ${ cause } ` , { cause } ) ;
7878 }
7979 }
8080
@@ -86,8 +86,8 @@ async function setWindowsUserLegacyProfile(userProfile: RecursivePartial<Setting
8686 try {
8787 await fs . promises . writeFile ( regFile , genResult ) ;
8888 await childProcess . spawnFile ( 'reg.exe' , [ 'IMPORT' , regFile ] , { stdio : 'ignore' } ) ;
89- } catch ( ex : any ) {
90- throw new Error ( `Error trying to create a user registry hive: ${ ex } ` ) ;
89+ } catch ( cause : any ) {
90+ throw new Error ( `Error trying to create a user registry hive: ${ cause } ` , { cause } ) ;
9191 }
9292 }
9393 }
@@ -208,7 +208,7 @@ export async function teardownApp(app: ElectronApplication) {
208208 // Send SIGTERM to the process group, wait three seconds, then send
209209 // SIGKILL and wait for one more second.
210210 for ( const [ signal , timeout ] of [ [ 'TERM' , 3_000 ] , [ 'KILL' , 1_000 ] ] as const ) {
211- let pids : string [ ] = [ ] ;
211+ let pids : string [ ] ;
212212
213213 try {
214214 const args = [ '-o' , 'pid=' , process . platform === 'darwin' ? '-g' : '--sid' , `${ pid } ` ] ;
0 commit comments