diff --git a/services/web/app/coffee/Features/Project/ProjectEntityHandler.coffee b/services/web/app/coffee/Features/Project/ProjectEntityHandler.coffee index e43b568cc9..cfdb079cb3 100644 --- a/services/web/app/coffee/Features/Project/ProjectEntityHandler.coffee +++ b/services/web/app/coffee/Features/Project/ProjectEntityHandler.coffee @@ -204,7 +204,7 @@ module.exports = ProjectEntityHandler = folders = _.select folders, (folder)-> return folder.length != 0 - ProjectGetter.getProjectWithoutDocLines project_id, (err, project)=> + ProjectGetter.getProjectWithOnlyFolders project_id, (err, project)=> if path == '/' logger.log project_id: project._id, "mkdir is only trying to make path of / so sending back root folder" return callback(null, [], project.rootFolder[0]) diff --git a/services/web/test/UnitTests/coffee/Project/ProjectEntityHandlerTests.coffee b/services/web/test/UnitTests/coffee/Project/ProjectEntityHandlerTests.coffee index 83d68f7bac..bbd2fe433a 100644 --- a/services/web/test/UnitTests/coffee/Project/ProjectEntityHandlerTests.coffee +++ b/services/web/test/UnitTests/coffee/Project/ProjectEntityHandlerTests.coffee @@ -79,7 +79,7 @@ describe 'ProjectEntityHandler', -> @parentFolder_id = "1jnjknjk" @newFolder = {_id:"newFolder_id_here"} @lastFolder = {_id:"123das", folders:[]} - @ProjectGetter.getProjectWithoutDocLines = sinon.stub().callsArgWith(1, null, @project) + @ProjectGetter.getProjectWithOnlyFolders = sinon.stub().callsArgWith(1, null, @project) @projectLocator.findElementByPath = (project_id, path, cb)=> @parentFolder = {_id:"parentFolder_id_here"} lastFolder = path.substring(path.lastIndexOf("/"))