From 2577843e516e7bda676dde68eea35d3a6bdec07f Mon Sep 17 00:00:00 2001 From: Ben Ogle Date: Fri, 16 Jan 2015 10:53:35 -0800 Subject: [PATCH] Explicitly check if the path to be deserialized is a dir --- src/project.coffee | 1 + 1 file changed, 1 insertion(+) diff --git a/src/project.coffee b/src/project.coffee index 536d8508e..2c5ca0291 100644 --- a/src/project.coffee +++ b/src/project.coffee @@ -68,6 +68,7 @@ class Project extends Model deserializeParams: (params) -> params.buffers = _.compact params.buffers.map (bufferState) -> # Check that buffer's file path is accessible + return if fs.isDirectorySync(bufferState.filePath) if bufferState.filePath try fs.closeSync(fs.openSync(bufferState.filePath, 'r'))