Don't return error if directory doesn't exist yet

This commit is contained in:
James Allen
2014-12-09 11:25:23 +00:00
parent 2c4fbd10ed
commit 84f3d3061d
2 changed files with 26 additions and 16 deletions

View File

@@ -47,9 +47,8 @@ module.exports = OutputFileFinder =
proc.on "error", callback
proc.on "close", (code) ->
if code != 0
error = new Error("find returned non-zero exit code: #{code}")
return callback(error)
logger.warn {directory, code}, "find returned error, directory likely doesn't exist"
return callback null, []
fileList = stdout.trim().split("\n")
fileList = fileList.map (file) ->
# Strip leading directory