2
2
mirror of https://github.com/Llewellynvdm/nativefier.git synced 2024-12-23 02:28:55 +00:00

return when erroring early

This commit is contained in:
Max Ogden 2015-05-11 12:10:26 -07:00
parent d32cf1034f
commit 923996f6ca

View File

@ -21,14 +21,14 @@ module.exports = function packager (opts, cb) {
switch (arch) {
case 'ia32': break
case 'x64': break
default: cb(new Error('Unsupported arch'))
default: return cb(new Error('Unsupported arch. Must be either ia32 or x64'))
}
switch (platform) {
case 'darwin': packager = mac; break
case 'linux': packager = linux; break
case 'win32': packager = win32; break
default: cb(new Error('Unsupported platform'))
default: return cb(new Error('Unsupported platform. Must be either darwin, linux, or win32'))
}
download({