Skip to content

Commit

Permalink
ktlint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ariskotsomitopoulos committed Jan 17, 2022
1 parent 879c4ff commit 52348e3
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -517,9 +517,9 @@ internal class RoomSyncHandler @Inject constructor(private val readReceiptHandle
*/
private fun deleteLocalEchosIfNeeded(insertType: EventInsertType, roomEntity: RoomEntity, eventList: List<Event>) {
// Skip deletion if we are on initial sync
if(insertType == EventInsertType.INITIAL_SYNC) return
if (insertType == EventInsertType.INITIAL_SYNC) return
// Skip deletion if there are no timeline events or there is no event received from the current user
if(eventList.firstOrNull { it.senderId == userId } == null) return
if (eventList.firstOrNull { it.senderId == userId } == null) return
roomEntity.sendingTimelineEvents.filter { timelineEvent ->
timelineEvent.root?.sendState == SendState.SENT
}.forEach {
Expand Down

0 comments on commit 52348e3

Please sign in to comment.