More receipt fixes
This commit is contained in:
parent
6e38fe2b08
commit
902fa3a171
2 changed files with 78 additions and 77 deletions
|
|
@ -358,7 +358,7 @@ export default {
|
||||||
RoomHistoryVisibility,
|
RoomHistoryVisibility,
|
||||||
DebugEvent,
|
DebugEvent,
|
||||||
MessageOperations,
|
MessageOperations,
|
||||||
VoiceRecorder
|
VoiceRecorder,
|
||||||
},
|
},
|
||||||
|
|
||||||
data() {
|
data() {
|
||||||
|
|
@ -563,7 +563,8 @@ export default {
|
||||||
{}
|
{}
|
||||||
);
|
);
|
||||||
const self = this;
|
const self = this;
|
||||||
this.timelineWindow.load(initialEventId, 20)
|
this.timelineWindow
|
||||||
|
.load(initialEventId, 20)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
console.log("This is", self);
|
console.log("This is", self);
|
||||||
self.events = self.timelineWindow.getEvents();
|
self.events = self.timelineWindow.getEvents();
|
||||||
|
|
@ -602,9 +603,9 @@ export default {
|
||||||
self.restartRRTimer();
|
self.restartRRTimer();
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.catch(err => {
|
.catch((err) => {
|
||||||
console.log("Error fetching events!", err, this);
|
console.log("Error fetching events!", err, this);
|
||||||
if (err.errcode == 'M_UNKNOWN' && initialEventId) {
|
if (err.errcode == "M_UNKNOWN" && initialEventId) {
|
||||||
// Try again without initial event!
|
// Try again without initial event!
|
||||||
this.onRoomJoined(null);
|
this.onRoomJoined(null);
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -612,7 +613,7 @@ export default {
|
||||||
this.events = this.timelineWindow.getEvents();
|
this.events = this.timelineWindow.getEvents();
|
||||||
this.initialLoadDone = true;
|
this.initialLoadDone = true;
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
onRoomNotJoined() {
|
onRoomNotJoined() {
|
||||||
|
|
@ -1108,8 +1109,8 @@ export default {
|
||||||
// Already sent this or too old...
|
// Already sent this or too old...
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
// Is it an incoming event?
|
// Make sure it's not a local echo event...
|
||||||
if (event.getSender() !== this.$matrix.currentUserId) {
|
if (!event.getId().startsWith("~")) {
|
||||||
// Send read receipt
|
// Send read receipt
|
||||||
this.$matrix.matrixClient
|
this.$matrix.matrixClient
|
||||||
.sendReadReceipt(event)
|
.sendReadReceipt(event)
|
||||||
|
|
@ -1166,7 +1167,7 @@ export default {
|
||||||
event.file,
|
event.file,
|
||||||
undefined
|
undefined
|
||||||
);
|
);
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
|
|
@ -143,7 +143,7 @@ export default {
|
||||||
if (!this.$matrix.currentUser) {
|
if (!this.$matrix.currentUser) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
return (this.$matrix.userDisplayName || this.$matrix.currentUser.userId.substring(1)).substring(0, 1).toUpperCase();
|
return (this.$matrix.userDisplayName || this.$matrix.currentUserId.substring(1)).substring(0, 1).toUpperCase();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue