Home: Presently the SDK is not able to handle correctly the context for the rooms recently joined.

PATCH: we force new initial sync
FIXME: this new initial sync should be removed when SDK will fix the issue
This commit is contained in:
giomfo
2014-10-17 16:44:41 +02:00
parent 276e970e15
commit ea949842cb
3 changed files with 25 additions and 0 deletions

View File

@@ -359,6 +359,13 @@
} else {
// Join the selected room
[mxHandler.mxSession joinRoom:publicRoom.room_id success:^{
// ******************
// Presently the SDK is not able to handle correctly the context for the room recently joined
// PATCH: we force new initial sync
// FIXME: this new initial sync should be removed when SDK will fix the issue
[mxHandler forceInitialSync];
// ******************
// Show joined room
[[AppDelegate theDelegate].masterTabBarController showRoom:publicRoom.room_id];
} failure:^(NSError *error) {

View File

@@ -36,6 +36,13 @@
- (void)logout;
// ******************
// Presently the SDK is not able to handle correctly the context for the room recently joined
// PATCH: we define temporarily a method to force initial sync
// FIXME: this method should be removed when SDK will fix the issue
- (void)forceInitialSync;
// ******************
- (BOOL)isAttachment:(MXEvent*)message;
- (BOOL)isNotification:(MXEvent*)message;
- (NSString*)displayTextFor:(MXEvent*)message inSubtitleMode:(BOOL)isSubtitle;

View File

@@ -108,6 +108,17 @@ static MatrixHandler *sharedHandler = nil;
self.accessToken = nil;
}
// ******************
// Presently the SDK is not able to handle correctly the context for the room recently joined
// PATCH: we define temporarily a method to force initial sync
// FIXME: this method should be removed when SDK will fix the issue
- (void)forceInitialSync {
[self closeSession];
notifyOpenSessionFailure = NO;
[self openSession];
}
// ******************
- (NSString *)homeServerURL {
return [[NSUserDefaults standardUserDefaults] objectForKey:@"homeserverurl"];
}