|
@@ -39,7 +39,7 @@ class Chef {
|
|
|
*/
|
|
|
async bake(input, recipeConfig, options) {
|
|
|
log.debug("Chef baking");
|
|
|
- const startTime = new Date().getTime(),
|
|
|
+ const startTime = Date.now(),
|
|
|
recipe = new Recipe(recipeConfig),
|
|
|
containsFc = recipe.containsFlowControl(),
|
|
|
notUTF8 = options && "treatAsUtf8" in options && !options.treatAsUtf8;
|
|
@@ -84,7 +84,7 @@ class Chef {
|
|
|
result: await this.dish.get(returnType, notUTF8),
|
|
|
type: Dish.enumLookup(this.dish.type),
|
|
|
progress: progress,
|
|
|
- duration: new Date().getTime() - startTime,
|
|
|
+ duration: Date.now() - startTime,
|
|
|
error: error
|
|
|
};
|
|
|
}
|
|
@@ -110,7 +110,7 @@ class Chef {
|
|
|
silentBake(recipeConfig) {
|
|
|
log.debug("Running silent bake");
|
|
|
|
|
|
- const startTime = new Date().getTime(),
|
|
|
+ const startTime = Date.now(),
|
|
|
recipe = new Recipe(recipeConfig),
|
|
|
dish = new Dish();
|
|
|
|
|
@@ -119,7 +119,7 @@ class Chef {
|
|
|
} catch (err) {
|
|
|
// Suppress all errors
|
|
|
}
|
|
|
- return new Date().getTime() - startTime;
|
|
|
+ return Date.now() - startTime;
|
|
|
}
|
|
|
|
|
|
|