Skip to content

Commit e359ca5

Browse files
authored
Merge pull request nodegit#1205 from rcjsuen/merge-cleanly
Write the index to a repository directly in merge-cleanly.js examples
2 parents 5b4bb8c + c0a8d97 commit e359ca5

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

examples/merge-cleanly.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -116,10 +116,7 @@ fse.remove(path.resolve(__dirname, repoDir))
116116
// the repository instead of just writing it.
117117
.then(function(index) {
118118
if (!index.hasConflicts()) {
119-
return index.write()
120-
.then(function() {
121-
return index.writeTreeTo(repository);
122-
});
119+
return index.writeTreeTo(repository);
123120
}
124121
})
125122

0 commit comments

Comments
 (0)