Skip to content
This repository was archived by the owner on Jun 7, 2020. It is now read-only.

Commit 4c07825

Browse files
authored
Merge pull request #2309 from RocketChat/fix/add-a-reaction-on-a-message-not-working
[FIX] Add a reaction not working/Chat list not showing/Chat list not updating/
2 parents eaccad7 + 76d4c75 commit 4c07825

6 files changed

Lines changed: 28 additions & 18 deletions

File tree

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ android {
1818
applicationId "chat.rocket.android"
1919
minSdkVersion versions.minSdk
2020
targetSdkVersion versions.targetSdk
21-
versionCode 2064
22-
versionName "3.3.1"
21+
versionCode 2067
22+
versionName "3.3.3"
2323
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
2424
multiDexEnabled true
2525

app/src/main/java/chat/rocket/android/chatroom/presentation/ChatRoomPresenter.kt

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1043,9 +1043,13 @@ class ChatRoomPresenter @Inject constructor(
10431043
}
10441044
}
10451045
}
1046-
} catch (ex: Exception) {
1047-
Timber.e(ex)
1048-
view.showMessage(ex.message!!)
1046+
} catch (exception: Exception) {
1047+
Timber.e(exception)
1048+
exception.message?.let {
1049+
view.showMessage(it)
1050+
}.ifNull {
1051+
view.showGenericErrorMessage()
1052+
}
10491053
}
10501054
}
10511055
}
@@ -1062,8 +1066,13 @@ class ChatRoomPresenter @Inject constructor(
10621066
}
10631067
}
10641068
}
1065-
} catch (ex: Exception) {
1066-
Timber.e(ex)
1069+
} catch (exception: Exception) {
1070+
Timber.e(exception)
1071+
exception.message?.let {
1072+
view.showMessage(it)
1073+
}.ifNull {
1074+
view.showGenericErrorMessage()
1075+
}
10671076
}
10681077
}
10691078
}
@@ -1078,8 +1087,13 @@ class ChatRoomPresenter @Inject constructor(
10781087
client.toggleReaction(messageId, emoji.removeSurrounding(":"))
10791088
}
10801089
logReactionEvent()
1081-
} catch (ex: RocketChatException) {
1082-
Timber.e(ex)
1090+
} catch (exception: RocketChatException) {
1091+
Timber.e(exception)
1092+
exception.message?.let {
1093+
view.showMessage(it)
1094+
}.ifNull {
1095+
view.showGenericErrorMessage()
1096+
}
10831097
}
10841098
}
10851099
}

app/src/main/java/chat/rocket/android/chatrooms/domain/FetchChatRoomsInteractor.kt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
11
package chat.rocket.android.chatrooms.domain
22

33
import chat.rocket.android.db.DatabaseManager
4-
import chat.rocket.android.db.model.ChatRoomEntity
5-
import chat.rocket.android.db.model.UserEntity
64
import chat.rocket.android.util.retryIO
75
import chat.rocket.core.RocketChatClient
86
import chat.rocket.core.internal.rest.chatRooms
9-
import chat.rocket.core.model.ChatRoom
10-
import chat.rocket.core.model.userId
117
import timber.log.Timber
128

139
class FetchChatRoomsInteractor(

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ buildscript {
1010
}
1111

1212
dependencies {
13-
classpath 'com.android.tools.build:gradle:3.3.2'
13+
classpath 'com.android.tools.build:gradle:3.4.0'
1414
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}"
1515
classpath "org.jetbrains.dokka:dokka-gradle-plugin:${versions.dokka}"
1616
classpath 'com.google.gms:google-services:4.2.0'

dependencies.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ext {
99
dokka : '0.9.16',
1010

1111
// For app
12-
kotlin : '1.3.21',
12+
kotlin : '1.3.31',
1313
coroutine : '1.1.1',
1414

1515
appCompat : '1.0.2',
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#Wed Oct 10 10:41:36 UYT 2018
1+
#Thu May 09 14:55:51 BRT 2019
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.2-all.zip
7-
distributionSha256Sum=b7aedd369a26b177147bcb715f8b1fc4fe32b0a6ade0d7fd8ee5ed0c6f731f2c
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-all.zip
7+
distributionSha256Sum=53b71812f18cdb2777e9f1b2a0f2038683907c90bdc406bc64d8b400e1fb2c3b

0 commit comments

Comments
 (0)