an-instance.js 185 B

12345
  1. module.exports = function (it, Constructor, name) {
  2. if (!(it instanceof Constructor)) {
  3. throw TypeError('Incorrect ' + (name ? name + ' ' : '') + 'invocation');
  4. } return it;
  5. };