             mkdirp '/tmp/cozy/test_parent_dir2', (err) ->
                 fs.writeFile filePath2, 'hello', (err) ->
                     should.not.exist err
-                    filesystem.createFileDoc filePath2, false, (err, res) ->
+                    filesystem.createFileDoc filePath2, (err, res) ->
                         should.not.exist err
                         should.exist res.id
                         pouch.db.query 'folder/byFullPath', key: "/#{parentDirName}", (err, res) ->



        it "does not update DB document when file exists", (done) =>
            filesystem.createFileDoc filePath, true, (err, res) =>
                pouch.db.query 'file/byFullPath', key: "/#{fileName}", (err, res) =>
                    should.not.exist err
                    for key, value in res.rows[0].value

        it "updates DB documents when file has changed", (done) =>
            setTimeout =>
                fs.writeFile filePath, 'hello2', (err) =>
                    filesystem.createFileDoc filePath, (err, res) =>
                        pouch.db.query 'file/byFullPath', key: "/#{fileName}", (err, res) =>
                            should.not.exist err
                            should.exist res.rows[0].value
