Skip to content

Commit 155e441

Browse files
committed
Don't synthesize ivars
1 parent 34d00fe commit 155e441

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

Classes/git/PBGitRepositoryWatcher.m

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -84,17 +84,14 @@ void PBGitRepositoryWatcherCallback(ConstFSEventStreamRef streamRef,
8484

8585
@implementation PBGitRepositoryWatcher
8686

87-
@synthesize repository, gitDir, workDir;
88-
8987
- (instancetype) initWithRepository:(PBGitRepository *)theRepository {
9088
self = [super init];
9189
if (!self) {
9290
return nil;
9391
}
9492

95-
repository = theRepository;
96-
97-
self.statusCache = [NSMutableDictionary new];
93+
_repository = theRepository;
94+
_statusCache = [NSMutableDictionary new];
9895

9996
if ([PBGitDefaults useRepositoryWatcher])
10097
[self start];
@@ -201,7 +198,7 @@ - (void) handleGitDirEventCallback:(NSArray *)eventPaths
201198
NSDictionary *eventInfo = @{kPBGitRepositoryEventTypeUserInfoKey:@(event),
202199
kPBGitRepositoryEventPathsUserInfoKey:paths};
203200

204-
[[NSNotificationCenter defaultCenter] postNotificationName:PBGitRepositoryEventNotification object:repository userInfo:eventInfo];
201+
[[NSNotificationCenter defaultCenter] postNotificationName:PBGitRepositoryEventNotification object:self.repository userInfo:eventInfo];
205202
}
206203
}
207204

@@ -245,7 +242,7 @@ - (void)handleWorkDirEventCallback:(NSArray *)eventPaths
245242
NSDictionary *eventInfo = @{kPBGitRepositoryEventTypeUserInfoKey:@(event),
246243
kPBGitRepositoryEventPathsUserInfoKey:paths};
247244

248-
[[NSNotificationCenter defaultCenter] postNotificationName:PBGitRepositoryEventNotification object:repository userInfo:eventInfo];
245+
[[NSNotificationCenter defaultCenter] postNotificationName:PBGitRepositoryEventNotification object:self.repository userInfo:eventInfo];
249246
}
250247
}
251248

@@ -254,7 +251,7 @@ - (NSString *)gitDir {
254251
}
255252

256253
- (NSString *)workDir {
257-
return !repository.gtRepo.isBare ? [repository.gtRepo.fileURL.path stringByStandardizingPath] : nil;
254+
return !self.repository.gtRepo.isBare ? [self.repository.gtRepo.fileURL.path stringByStandardizingPath] : nil;
258255
}
259256

260257
- (void) _initializeStream {

0 commit comments

Comments
 (0)