Fix some warning and handle servers that don't support "m.thread" using old "io.element.thread"
This commit is contained in:
parent
23b69b5503
commit
ecb4b1717b
2 changed files with 4 additions and 3 deletions
|
|
@ -6,6 +6,7 @@ import { AutoDiscovery } from 'matrix-js-sdk';
|
|||
import User from '../models/user';
|
||||
const prettyBytes = require("pretty-bytes");
|
||||
import Hammer from "hammerjs";
|
||||
import { Thread } from 'matrix-js-sdk/lib/models/thread';
|
||||
|
||||
export const STATE_EVENT_ROOM_DELETION_NOTICE = "im.keanu.room_deletion_notice";
|
||||
export const STATE_EVENT_ROOM_DELETED = "im.keanu.room_deleted";
|
||||
|
|
@ -399,7 +400,7 @@ class Util {
|
|||
// If thread root (an eventId) is set, add that here
|
||||
if (threadRoot) {
|
||||
messageContent["m.relates_to"] = {
|
||||
"rel_type": "m.thread",
|
||||
"rel_type": Thread.hasServerSideSupport ? "m.thread" : "io.element.thread",
|
||||
"event_id": threadRoot
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue