source: trip-planner-front/node_modules/object-is/implementation.js@ b738035

Last change on this file since b738035 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 286 bytes
Line 
1'use strict';
2
3var numberIsNaN = function (value) {
4 return value !== value;
5};
6
7module.exports = function is(a, b) {
8 if (a === 0 && b === 0) {
9 return 1 / a === 1 / b;
10 }
11 if (a === b) {
12 return true;
13 }
14 if (numberIsNaN(a) && numberIsNaN(b)) {
15 return true;
16 }
17 return false;
18};
19
Note: See TracBrowser for help on using the repository browser.