3 module.exports = protochain;
5 function protochain(obj) {
7 var target = getPrototypeOf(obj);
10 target = getPrototypeOf(target);
16 function getPrototypeOf(obj) {
19 }if (isPrimitive(obj)) obj = Object(obj);
20 return Object.getPrototypeOf(obj);
23 function isPrimitive(item) {
24 return item === null || typeof item !== "object";