summaryrefslogtreecommitdiff
path: root/tools/eslint/node_modules/escope/node_modules/es6-map/node_modules/es5-ext/boolean/is-boolean.js
blob: 5d1a802e11211cb0fcd2505257cd5924e09532c6 (plain)
1
2
3
4
5
6
7
8
9
10
'use strict';

var toString = Object.prototype.toString

  , id = toString.call(true);

module.exports = function (x) {
	return (typeof x === 'boolean') || ((typeof x === 'object') &&
		((x instanceof Boolean) || (toString.call(x) === id)));
};