diff options
author | Alexey Rusakov <Kitsune-Ral@users.sf.net> | 2022-01-23 10:32:40 +0100 |
---|---|---|
committer | Alexey Rusakov <Kitsune-Ral@users.sf.net> | 2022-01-23 17:12:44 +0100 |
commit | 9ae0d4e45befc79f621b03dc4efe869cd4277e06 (patch) | |
tree | 70cf1dac2662b198cb749b3e54231c9d15e109d2 /.github/ISSUE_TEMPLATE/bug_report.md | |
parent | a1fcad591968ec717214a73a2dbe78f608207bc5 (diff) | |
download | libquotient-9ae0d4e45befc79f621b03dc4efe869cd4277e06.tar.gz libquotient-9ae0d4e45befc79f621b03dc4efe869cd4277e06.zip |
Refactor Room::setState()
There are two important aspects here:
- Introducing Room::setState(evtType, stateKey, contentJson). These
components are ultimately what is getting sent to the homeserver,
so it makes sense to expose a respective `setState()` overload.
Unlike setState(event) the new overload can be Q_INVOKABLE.
- Room::setState() is no more const. Although it doesn't cause any
changes in Room class (and only transient changes in Room::Private),
it ultimately initiates a change in the room state, so calling it
const has always been a bit of hypocrisy. If you relied on that, you
most likely do something wrong (see the fix to User::rename()
in this very commit for a simple example of such wrongness).
Also: the backend is simplified by calling the original templated
Room::setState() instead of calling Room::Private::requestSetState()
that does exactly the same thing.
Diffstat (limited to '.github/ISSUE_TEMPLATE/bug_report.md')
0 files changed, 0 insertions, 0 deletions