Skip to content

Commit 57abefe

Browse files
committed
[4] branch names with slash
1 parent 1a803bd commit 57abefe

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

PBGitSidebarController.m

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -154,12 +154,13 @@ - (void) observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(
154154
}
155155

156156
for(PBGitSVBranchItem* branch in [branches children]){
157-
NSString *bName=[branch title];
158-
[branch setAhead:[self countCommintsOf:[NSString stringWithFormat:@"origin/%@..%@",bName,bName]]];
159-
[branch setBehind:[self countCommintsOf:[NSString stringWithFormat:@"%@..origin/%@",bName,bName]]];
160-
[branch setIsCheckedOut:[branch.revSpecifier isEqual:[repository headRef]]];
157+
if([branch isKindOfClass:[PBGitSVBranchItem class]]){
158+
NSString *bName=[branch title];
159+
[branch setAhead:[self countCommintsOf:[NSString stringWithFormat:@"origin/%@..%@",bName,bName]]];
160+
[branch setBehind:[self countCommintsOf:[NSString stringWithFormat:@"%@..origin/%@",bName,bName]]];
161+
[branch setIsCheckedOut:[branch.revSpecifier isEqual:[repository headRef]]];
162+
}
161163
}
162-
163164
}else{
164165
[super observeValueForKeyPath:keyPath ofObject:object change:change context:context];
165166
}

0 commit comments

Comments
 (0)