Merge pull request #12984 from Snuffleupagus/more-Date-now

Replace a few `new Date().getTime()` instances with `Date.now()`
This commit is contained in:
Tim van der Meij 2021-02-12 00:06:45 +01:00 committed by GitHub
commit 069d5b1086
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -40,7 +40,7 @@ const TestReporter = function (browser) {
} }
this.now = function () { this.now = function () {
return new Date().getTime(); return Date.now();
}; };
this.jasmineStarted = function (suiteInfo) { this.jasmineStarted = function (suiteInfo) {

View File

@ -102,7 +102,7 @@ class PDFPresentationMode {
evt.preventDefault(); evt.preventDefault();
const delta = normalizeWheelEventDelta(evt); const delta = normalizeWheelEventDelta(evt);
const currentTime = new Date().getTime(); const currentTime = Date.now();
const storedTime = this.mouseScrollTimeStamp; const storedTime = this.mouseScrollTimeStamp;
// If we've already switched page, avoid accidentally switching again. // If we've already switched page, avoid accidentally switching again.