This commit is contained in:
Devine Lu Linvega 2019-02-16 15:11:27 +09:00
parent 05805a2b6b
commit a45f9dd308

View File

@ -73,7 +73,7 @@ function Theme (_default) {
const fs = require('fs')
const { dialog, app } = require('electron').remote
let paths = dialog.showOpenDialog(app.win, { properties: ['openFile'], filters: [{ name: 'Themes', extensions: ['svg'] }] })
if (!paths) { console.log('Nothing to load') }
if (!paths) { console.log('Nothing to load'); return; }
fs.readFile(paths[0], 'utf8', function (err, data) {
if (err) throw err
themer.load(data)