var baseGet = require('../base/baseGet')
var baseSlice = require('../base/baseSlice')
var isArguments = require('../lang/isArguments')
var isArray = require('../lang/isArray')
var isIndex = require('../lang/isIndex')
var isKey = require('../lang/isKey')
var isLength = require('../lang/isLength')
var last = require('../array/last')
var toPath = require('../string/toPath')
var hasOwn = require('./hasOwn')

// Checks if `path` is a direct property.

function has (object, path) {
  if (object == null) return false

  var result = hasOwnProperty.call(object, path)
  if (!result && !isKey(path)) {
    path = toPath(path)
    object = path.length === 1 ? object : baseGet(object, baseSlice(path, 0, 1))
    if (object == null) return false
    path = last(path)
    result = hasOwn(object, path)
  }
  return result || (
    isLength(object.length)
    && isIndex(path, object.length)
    && (isArray(object)
    || isArguments(object))
  )
}

module.exports = has

@@ -5,16 +5,20 @@
 baseGet 
+    
 = requir
@@ -52,16 +52,18 @@
 seSlice 
+  
 = requir
@@ -146,16 +146,20 @@
 isArray 
+    
 = requir
@@ -191,16 +191,20 @@
 isIndex 
+    
 = requir
@@ -234,16 +234,22 @@
 r isKey 
+      
 = requir
@@ -280,16 +280,19 @@
 sLength 
+   
 = requir
@@ -322,16 +322,23 @@
 ar last 
+       
 = requir
@@ -367,16 +367,21 @@
  toPath 
+     
 = requir
@@ -413,16 +413,21 @@
  hasOwn 
+     
 = requir
@@ -575,21 +575,8 @@
 sOwn
-Property.call
 (obj
@@ -586,16 +586,17 @@
 , path)%0A
+%0A
   if (!r
@@ -640,24 +640,25 @@
 oPath(path)%0A
+%0A
     object =
@@ -675,16 +675,22 @@
 th === 1
+%0A     
  ? objec
@@ -690,16 +690,22 @@
 ? object
+%0A     
  : baseG
@@ -738,16 +738,17 @@
  0, 1))%0A
+%0A
     if (
@@ -776,16 +776,17 @@
 n false%0A
+%0A
     path

reformat object/hasProp.js