Skip to content

m.topic field of m.room.topic has wrong format #4902

@zecakeh

Description

@zecakeh

The JS SDK expects this format:

{
    "topic": "All about **pizza**",
    "m.topic": [{
        "body": "All about **pizza**",
        "mimetype": "text/plain",
    }, {
        "body": "All about <b>pizza</b>",
        "mimetype": "text/html",
    }],
}

But the actual format defined in the spec and MSC3765 is:

{
    "topic": "All about **pizza**",
    "m.topic": {
        "m.text": [{
            "body": "All about **pizza**",
            "mimetype": "text/plain",
        }, {
            "body": "All about <b>pizza</b>",
            "mimetype": "text/html",
        }],
    }
}

To clarify, currently the SDK expects m.topic to be an array of objects, but m.topic should be an object with an m.text field that is an array of objects.

Metadata

Metadata

Assignees

No one assigned

    Labels

    O-OccasionalAffects or can be seen by some users regularly or most users rarelyS-MajorSeverely degrades major functionality or product features, with no satisfactory workaroundT-Defect

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions