mirror of
https://github.com/balena-io/etcher.git
synced 2025-07-21 18:26:32 +00:00
Lazily import Electron from child-writer process
No idea how this *used* to work, but it doesn’t since 887ec428 and this is fixing it properly. Change-type: patch
This commit is contained in:
parent
286c74b41b
commit
851219f835
@ -15,7 +15,6 @@
|
||||
*/
|
||||
|
||||
import axios from 'axios';
|
||||
import { app, remote } from 'electron';
|
||||
import { Dictionary } from 'lodash';
|
||||
|
||||
import * as errors from './errors';
|
||||
@ -50,6 +49,7 @@ export async function delay(duration: number): Promise<void> {
|
||||
}
|
||||
|
||||
export function getAppPath(): string {
|
||||
const { app, remote } = require('electron');
|
||||
return (
|
||||
(app || remote.app)
|
||||
.getAppPath()
|
||||
|
Loading…
x
Reference in New Issue
Block a user