UNPKG

core-js

Version:
11 lines (8 loc) 312 B
'use strict'; var isCallable = require('../internals/is-callable'); var $String = String; var $TypeError = TypeError; module.exports = function (argument) { if (typeof argument == 'object' || isCallable(argument)) return argument; throw $TypeError("Can't set " + $String(argument) + ' as a prototype'); };