mirror of
https://github.com/tijder/SmsMatrix.git
synced 2026-03-02 03:40:08 +00:00
Dont create a new room for a incomming call
This commit is contained in:
@@ -145,6 +145,7 @@ public class Matrix {
|
||||
if (session != null && session.isAlive()) {
|
||||
Room room = getRoomByPhonenumber(phoneNumber);
|
||||
if (room == null) {
|
||||
if (!type.equals("m.notice")) {
|
||||
Log.e(TAG, "sendMessage: not found" );
|
||||
session.createRoomDirectMessage(realUserid, new SimpleApiCallback<String>() {
|
||||
@Override
|
||||
@@ -156,6 +157,7 @@ public class Matrix {
|
||||
SendMesageToRoom(room, body, type);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
changeDisplayname(room.getRoomId(), getContactName(phoneNumber, context));
|
||||
SendMesageToRoom(room, body, type);
|
||||
|
||||
Reference in New Issue
Block a user