@@ -84,17 +84,14 @@ void PBGitRepositoryWatcherCallback(ConstFSEventStreamRef streamRef,
84
84
85
85
@implementation PBGitRepositoryWatcher
86
86
87
- @synthesize repository, gitDir, workDir;
88
-
89
87
- (instancetype ) initWithRepository : (PBGitRepository *)theRepository {
90
88
self = [super init ];
91
89
if (!self) {
92
90
return nil ;
93
91
}
94
92
95
- repository = theRepository;
96
-
97
- self.statusCache = [NSMutableDictionary new ];
93
+ _repository = theRepository;
94
+ _statusCache = [NSMutableDictionary new ];
98
95
99
96
if ([PBGitDefaults useRepositoryWatcher ])
100
97
[self start ];
@@ -201,7 +198,7 @@ - (void) handleGitDirEventCallback:(NSArray *)eventPaths
201
198
NSDictionary *eventInfo = @{kPBGitRepositoryEventTypeUserInfoKey :@(event),
202
199
kPBGitRepositoryEventPathsUserInfoKey :paths};
203
200
204
- [[NSNotificationCenter defaultCenter ] postNotificationName: PBGitRepositoryEventNotification object: repository userInfo: eventInfo];
201
+ [[NSNotificationCenter defaultCenter ] postNotificationName: PBGitRepositoryEventNotification object: self . repository userInfo: eventInfo];
205
202
}
206
203
}
207
204
@@ -245,7 +242,7 @@ - (void)handleWorkDirEventCallback:(NSArray *)eventPaths
245
242
NSDictionary *eventInfo = @{kPBGitRepositoryEventTypeUserInfoKey :@(event),
246
243
kPBGitRepositoryEventPathsUserInfoKey :paths};
247
244
248
- [[NSNotificationCenter defaultCenter ] postNotificationName: PBGitRepositoryEventNotification object: repository userInfo: eventInfo];
245
+ [[NSNotificationCenter defaultCenter ] postNotificationName: PBGitRepositoryEventNotification object: self . repository userInfo: eventInfo];
249
246
}
250
247
}
251
248
@@ -254,7 +251,7 @@ - (NSString *)gitDir {
254
251
}
255
252
256
253
- (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 ;
258
255
}
259
256
260
257
- (void ) _initializeStream {
0 commit comments