diff --git a/Yep/Realm/Models.swift b/Yep/Realm/Models.swift index dda97c80..519224d0 100644 --- a/Yep/Realm/Models.swift +++ b/Yep/Realm/Models.swift @@ -365,11 +365,11 @@ class Conversation: Object { switch type { case ConversationType.OneToOne.rawValue: if let withFriend = withFriend { - return withFriend.userID + return "user" + withFriend.userID } case ConversationType.Group.rawValue: if let withGroup = withGroup { - return withGroup.groupID + return "group" + withGroup.groupID } default: break diff --git a/Yep/Services/YepServiceSync.swift b/Yep/Services/YepServiceSync.swift index 215f0525..603d5461 100644 --- a/Yep/Services/YepServiceSync.swift +++ b/Yep/Services/YepServiceSync.swift @@ -895,7 +895,7 @@ func syncMessageWithMessageInfo(messageInfo: JSONDictionary, inRealm realm: Real // Do furtherAction after sync - if let sectionDateMessageID = sectionDateMessageID{ + if let sectionDateMessageID = sectionDateMessageID { furtherAction?(messageIDs: [sectionDateMessageID, messageID]) } else { furtherAction?(messageIDs: [messageID])