Skip to content

Commit f04fc75

Browse files
committed
Fix entryWithPath:error:
1 parent 7d8d8fa commit f04fc75

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ObjectiveGit/GTTree.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ - (GTTreeEntry *)entryWithName:(NSString *)name {
7171
- (GTTreeEntry *)entryWithPath:(NSString *)path error:(NSError **)error {
7272
git_tree_entry *internalEntry = NULL;
7373
int gitError = git_tree_entry_bypath(&internalEntry, self.git_tree, path.UTF8String);
74-
if (error != GIT_OK) {
74+
if (gitError != GIT_OK) {
7575
if (error != NULL) *error = [NSError git_errorFor:gitError description:@"Failed to get tree entry %@", path];
7676
return nil;
7777
}

0 commit comments

Comments
 (0)