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

Fix bug when no injection scripts is passed

This commit is contained in:
Jia Hao 2016-02-25 16:51:23 +08:00
parent 9b3de78d37
commit 1c334a3d7d

View File

@ -37,6 +37,11 @@ function buildApp(src, dest, options, callback) {
} }
function maybeCopyScripts(srcs, dest) { function maybeCopyScripts(srcs, dest) {
if (!srcs) {
return new Promise(resolve => {
resolve();
});
}
const promises = srcs.map(src => { const promises = srcs.map(src => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
if (!fs.existsSync(src)) { if (!fs.existsSync(src)) {