 
       # provide a 'file' action
       action.file = (result) =>
-        if result.path.isFile()
-          action.tempFiles.push result.path
-          result.file = result.path
-          @emit 'file', result
+        path = result.path
+        if path.isFile()
+          action.tempFiles[action.tempFiles.length] = path
+          # result.file = path
+          @emit 'file', path
 
       # provide a 'files' action
       action.files = =>
         results.found.files += action.tempFiles.length
-        @emit 'files', files:action.tempFiles
+        @emit 'files', action.tempFiles
         action.tempFiles = []
 
     # if the 'dirs' mode is active

#  2. dirator = require('dirator')
#     dirator options
#  3. require('dirator')(options)
module.exports = (args...) -> new Dirator(args...).run()
module.exports.Dirator = Dirator

# Provide convenience functions prebuilt with mode:

          results.found?.dirs += 1 if results.found?.dirs?

          # only add this directory to our workload if `recurse` is on
          dirArray[dirArray.length] = path if @recurse

          # add directory to our results only if we're tracking them
          results?.dirs?.push path
