Merge pull request #830 from embark-framework/feature/process-wrapper-options

Better manage default options
This commit is contained in:
Iuri Matias 2018-09-14 18:09:41 -04:00 committed by GitHub
commit 8b28bb9691
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -14,10 +14,11 @@ class ProcessWrapper {
*
* @param {Options} options pingParent: true by default
*/
constructor(options = {pingParent: true}) {
constructor(options = {}) {
this.options = Object.assign({pingParent: true}, options);
this.interceptLogs();
this.events = new Events();
if(options.pingParent) {
if(this.options.pingParent) {
this.pingParent();
}
}