Commit 3c33ac97 authored by Philipp Nowinski's avatar Philipp Nowinski
Browse files

[BUGFIX] fix default task + code cleanup

parent 7076891a
......@@ -256,10 +256,9 @@ module.exports = class Css extends Task {
* @param {String} _source The CSS as a string
*/
_imageDimensions(_source) {
let newSource = new ImageDimensions(_source, {
return new ImageDimensions(_source, {
imageBasePath: this._getFullPath(this._config.directories.images)
}).process();
return newSource;
}
/**
......
......@@ -13,11 +13,10 @@ module.exports = class Default extends Task {
async run() {
return new Promise(async resolve => {
let serverTask = this._settings.tasks.server();
await new serverTask().run();
new serverTask().run();
let watchTask = this._settings.tasks.watch();
await new watchTask().run();
resolve();
new watchTask().run();
});
}
}
};
......@@ -98,4 +98,4 @@ module.exports = class Watch extends Task {
resolve();
});
}
}
};
......@@ -104,4 +104,4 @@ module.exports = class Open extends Task {
});
}
}
};
......@@ -58,4 +58,4 @@ module.exports = class Server extends Task {
}
}
}
};
......@@ -123,4 +123,4 @@ module.exports = class Watch extends Task {
let file = _file.replace(/\\/g, '/');
settings.setExtension(file.split(this._config.directories.basePath)[1].split('/')[0]);
}
}
};
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment