Skip to content

Commit fb0b054

Browse files
author
sm-deployer
authored
Merge pull request #429 from salemove/bugfix/null_operator_image_fix
2 parents f13b50b + 31525e0 commit fb0b054

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

widgetssdk/src/main/java/com/glia/widgets/chat/controller/ChatController.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,7 @@ class ChatController(
623623
viewCallback?.minimizeView()
624624
}
625625

626-
private fun operatorConnected(operatorName: String, profileImgUrl: String) {
626+
private fun operatorConnected(operatorName: String, profileImgUrl: String?) {
627627
val items: MutableList<ChatItem> = chatState.chatItems.toMutableList()
628628
if (chatState.operatorStatusItem != null) {
629629
// remove previous operator status item
@@ -654,7 +654,7 @@ class ChatController(
654654
emitChatItems(chatState.changeItems(items))
655655
}
656656

657-
private fun operatorChanged(operatorName: String, profileImgUrl: String) {
657+
private fun operatorChanged(operatorName: String, profileImgUrl: String?) {
658658
val items: MutableList<ChatItem> = chatState.chatItems.toMutableList()
659659
val operatorStatusItem = OperatorStatusItem.OperatorJoinedStatusItem(
660660
chatState.companyName,

widgetssdk/src/main/java/com/glia/widgets/helper/Utils.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
import java.util.concurrent.TimeUnit;
4444

4545
public class Utils {
46+
@Nullable
4647
public static String getOperatorImageUrl(Operator operator) {
4748
return operator.getPicture() != null ? operator.getPicture().getURL().orElse(null) : null;
4849
}

0 commit comments

Comments
 (0)