Skip to content

Commit

Permalink
fix system tray error
Browse files Browse the repository at this point in the history
  • Loading branch information
AkinariHex committed Mar 26, 2021
1 parent 58c1552 commit d72cf65
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,25 @@ if (!fs.existsSync('./teams')) {
})
}

//create settings file at first run
if (!fs.existsSync('./settings.json')) {
let data = {
"apikey":"",
"matchid":"",
"stage":"",
"nofmaps":"",
"warmups":"",
"bestof":"",
"matchtype":"",
"userid":"",
"reverse":"",
"visualizerstyle":"",
"compactUI":false,
"systemTray":true
}
fs.writeFileSync('./settings.json', JSON.stringify(data))
}

function readSettingsJson() {
try {
let data = JSON.parse(fs.readFileSync('./settings.json'))
Expand Down

0 comments on commit d72cf65

Please sign in to comment.