소스 검색

skip cache directory error when empty

Brian Gough 11 년 전
부모
커밋
c26de9554d
1개의 변경된 파일과 1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      services/clsi/app/coffee/OutputCacheManager.coffee

+ 1 - 0
services/clsi/app/coffee/OutputCacheManager.coffee

@@ -83,6 +83,7 @@ module.exports = OutputCacheManager =
 		# look in compileDir for build dirs and delete if > N or age of mod time > T
 		fs.readdir cacheRoot, (err, results) ->
 			if err?
+				return callback(null) if err.code == 'ENOENT'	# cache directory is empty
 				logger.error err: err, project_id: cacheRoot, "error clearing cache"
 				return callback(err)