Socket
Socket
Sign inDemoInstall

electron-json-config

Package Overview
Dependencies
0
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.5.1 to 1.5.2

2

package.json
{
"name": "electron-json-config",
"version": "1.5.1",
"version": "1.5.2",
"description": "Simply set and get configuration from a json file for your Electron app",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -11,3 +11,3 @@ 'use strict';

(electron.app || electron.remote.app).on('ready', () => {
let readConfig = () => {
if(!u.exists(file)) {

@@ -18,5 +18,13 @@ fs.writeFileSync(file, '{}');

config = JSON.parse(fs.readFileSync(file));
});
};
if ((electron.app && electron.app.isReady()) || (electron.remote.app && electron.remote.app.isReady())) {
readConfig();
} else {
(electron.app || electron.remote.app).on('ready', () => {
readConfig();
});
}
exports.file = function() {

@@ -23,0 +31,0 @@ return file;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc