diff options
Diffstat (limited to 'room.cpp')
-rw-r--r-- | room.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -24,6 +24,7 @@ #include "jobs/generated/leaving.h" #include "jobs/generated/receipts.h" #include "jobs/generated/redaction.h" +#include "jobs/generated/account-data.h" #include "jobs/setroomstatejob.h" #include "events/simplestateevents.h" #include "events/roomavatarevent.h" @@ -202,6 +203,13 @@ class Room::Private */ void processRedaction(RoomEventPtr redactionEvent); + template <typename EvT> + SetAccountDataPerRoomJob* setAccountData(const EvT& event) + { + return connection->callApi<SetAccountDataPerRoomJob>( + connection->userId(), id, EvT::typeId(), event.toJson()); + } + QJsonObject toJson() const; private: |