Skip to content

Commit 15cdd2f

Browse files
authored
Merge pull request #2416 from adroitwhiz/no-relativetime
Remove Timer.relativeTime
2 parents 83b9e67 + 83bcbb8 commit 15cdd2f

File tree

2 files changed

+1
-21
lines changed

2 files changed

+1
-21
lines changed

src/util/timer.js

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* ... pass some time ...
99
* var timeDifference = timer.timeElapsed();
1010
* ---
11-
* Or, you can use the `time` and `relativeTime`
11+
* Or, you can use the `time` function
1212
* to do some measurement yourself.
1313
*/
1414

@@ -68,17 +68,6 @@ class Timer {
6868
return this.nowObj.now();
6969
}
7070

71-
/**
72-
* Returns a time accurate relative to other times produced by this function.
73-
* If possible, will use sub-millisecond precision.
74-
* If not, will use millisecond precision.
75-
* Not guaranteed to produce the same absolute values per-system.
76-
* @returns {number} ms-scale accurate time relative to other relative times.
77-
*/
78-
relativeTime () {
79-
return this.nowObj.now();
80-
}
81-
8271
/**
8372
* Start a timer for measuring elapsed time,
8473
* at the most accurate precision possible.

test/fixtures/mock-timer.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -78,15 +78,6 @@ class MockTimer {
7878
return this._mockTime;
7979
}
8080

81-
/**
82-
* Returns a time accurate relative to other times produced by this function.
83-
* @returns {number} ms-scale accurate time relative to other relative times.
84-
* @memberof MockTimer
85-
*/
86-
relativeTime () {
87-
return this._mockTime;
88-
}
89-
9081
/**
9182
* Start a timer for measuring elapsed time.
9283
* @memberof MockTimer

0 commit comments

Comments
 (0)