if ((self = [super init])) {
self.pithos = aPithos;
self.sharingAccount = @"";
- self.childrenUpdatedNotificationName = [NSString stringWithString:@"PithosSharingAccountsNodeChildrenUpdated"];
}
return self;
}
node.parent = self;
node.shared = shared;
node.sharingAccount = account.name;
+ node.inheritChildrenUpdatedNotificationName = inheritChildrenUpdatedNotificationName;
if (children) {
NSUInteger oldIndex = [children indexOfObject:node];
if (oldIndex != NSNotFound) {
@synchronized(self) {
freshness = PithosNodeStateRefreshFinished;
}
- if (childrenUpdatedNotificationName) {
- // Notify observers that children are updated
- [[NSNotificationCenter defaultCenter] postNotificationName:childrenUpdatedNotificationName object:self];
- }
+ [self postChildrenUpdatedNotificationName];
} else {
[sharingAccountsRequest release];
// Do an additional request to fetch more objects