Check if running electron via user agent
@@ -15,6 +15,9 @@ export class ElectronService {
* Returns true if electron is detected
*/
isElectron(): boolean {
+ if (typeof process === 'undefined') {
+ return false;
+ }
return (
process && process.versions && process.versions.electron !== undefined
);
