mirror of
https://github.com/atom/atom.git
synced 2026-04-28 03:01:47 -04:00
Add native traverseTree
This commit is contained in:
@@ -103,13 +103,7 @@ module.exports =
|
||||
@makeDirectory(path)
|
||||
|
||||
traverseTree: (rootPath, fn) ->
|
||||
recurse = null
|
||||
prune = -> recurse = false
|
||||
|
||||
for path in @list(rootPath)
|
||||
recurse = true
|
||||
fn(path, prune)
|
||||
@traverseTree(path, fn) if recurse and @isDirectory(path)
|
||||
$native.traverseTree(rootPath, fn)
|
||||
|
||||
lastModified: (path) ->
|
||||
$native.lastModified(path)
|
||||
|
||||
Reference in New Issue
Block a user