Fix passing variable down to evaluate context

pull/21833/head
Germain Souquet 2021-06-16 11:39:04 +01:00
parent 19cae42161
commit 9f8d04ab9a
1 changed files with 6 additions and 6 deletions

View File

@ -28,13 +28,13 @@ module.exports.delay = function(ms) {
};
module.exports.measureStart = function(session, name) {
return session.page.evaluate(() => {
window.mxPerformanceMonitor.start(name);
});
return session.page.evaluate(_name => {
window.mxPerformanceMonitor.start(_name);
}, name);
};
module.exports.measureStop = function(session, name) {
return session.page.evaluate(() => {
window.mxPerformanceMonitor.stop(name);
});
return session.page.evaluate(_name => {
window.mxPerformanceMonitor.stop(_name);
}, name);
};