main
Last change
on this file was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago |
Update repo after prototype presentation
|
-
Property mode
set to
100644
|
File size:
396 bytes
|
Rev | Line | |
---|
[d565449] | 1 | 'use strict';
|
---|
| 2 |
|
---|
| 3 | var floor = require('./floor');
|
---|
| 4 | var modulo = require('./modulo');
|
---|
| 5 |
|
---|
| 6 | var timeConstants = require('../helpers/timeConstants');
|
---|
| 7 | var msPerMinute = timeConstants.msPerMinute;
|
---|
| 8 | var MinutesPerHour = timeConstants.MinutesPerHour;
|
---|
| 9 |
|
---|
| 10 | // https://262.ecma-international.org/5.1/#sec-15.9.1.10
|
---|
| 11 |
|
---|
| 12 | module.exports = function MinFromTime(t) {
|
---|
| 13 | return modulo(floor(t / msPerMinute), MinutesPerHour);
|
---|
| 14 | };
|
---|
Note:
See
TracBrowser
for help on using the repository browser.