00001 var isObject = require('./isObject'), 00002 isPrototype = require('./_isPrototype'), 00003 nativeKeysIn = require('./_nativeKeysIn'); 00004 00006 var objectProto = Object.prototype; 00007 00009 var hasOwnProperty = objectProto.hasOwnProperty; 00010 00018 function baseKeysIn(object) { 00019 if (!isObject(object)) { 00020 return nativeKeysIn(object); 00021 } 00022 var isProto = isPrototype(object), 00023 result = []; 00024 00025 for (var key in object) { 00026 if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) { 00027 result.push(key); 00028 } 00029 } 00030 return result; 00031 } 00032 00033 module.exports = baseKeysIn;