Skip to content

Commit 85e631a

Browse files
committed
added missing isX (Diff.DELTA) functions to ConvenientPatch
1 parent 5b014a6 commit 85e631a

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

lib/convenient_patch.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,4 +144,20 @@ ConvenientPatch.prototype.isTypeChange = function() {
144144
return this.status() == Diff.DELTA.TYPECHANGE;
145145
};
146146

147+
/**
148+
* Is this an undreadable patch?
149+
* @return {Boolean}
150+
*/
151+
ConvenientPatch.prototype.isUnreadable = function() {
152+
return this.status() == Diff.DELTA.UNREADABLE;
153+
}
154+
155+
/**
156+
* Is this a conflicted patch?
157+
* @return {Boolean}
158+
*/
159+
ConvenientPatch.prototype.isConflicted = function() {
160+
return this.status() == Diff.DELTA.CONFLICTED;
161+
}
162+
147163
NodeGit.ConvenientPatch = ConvenientPatch;

0 commit comments

Comments
 (0)