diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2019-08-02 09:32:49 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2019-08-02 09:32:49 +0900 |
commit | 35cfef7a4253d49a37e5ce21c337fbb3d2633c42 (patch) | |
tree | dfcc77c4e404b6b8f07a4c9ee6283e70e4723883 /lib/events/event.h | |
parent | 5b37e15d6a57d3b689c88f5cfce7afea9787a034 (diff) | |
parent | 5b236dfe895c7766002559570aa29c9033009228 (diff) | |
download | libquotient-35cfef7a4253d49a37e5ce21c337fbb3d2633c42.tar.gz libquotient-35cfef7a4253d49a37e5ce21c337fbb3d2633c42.zip |
Merge branch 'master' into use-clang-format
Diffstat (limited to 'lib/events/event.h')
-rw-r--r-- | lib/events/event.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/events/event.h b/lib/events/event.h index 8056ccbe..d6525281 100644 --- a/lib/events/event.h +++ b/lib/events/event.h @@ -58,11 +58,13 @@ ptrCast(event_ptr_tt<SourceT>&& ptr) // === Standard Matrix key names and basicEventJson() === static const auto TypeKey = QStringLiteral("type"); +static const auto BodyKey = QStringLiteral("body"); static const auto ContentKey = QStringLiteral("content"); static const auto EventIdKey = QStringLiteral("event_id"); static const auto UnsignedKey = QStringLiteral("unsigned"); static const auto StateKeyKey = QStringLiteral("state_key"); static const auto TypeKeyL = "type"_ls; +static const auto BodyKeyL = "body"_ls; static const auto ContentKeyL = "content"_ls; static const auto EventIdKeyL = "event_id"_ls; static const auto UnsignedKeyL = "unsigned"_ls; @@ -391,10 +393,8 @@ template <typename BaseEventT, typename FnT> inline std::enable_if_t<is_event<BaseEventT>() && needs_cast<BaseEventT, FnT>(), fn_return_t<FnT>> // non-voidness is guarded by // defaultValue type - visit(const BaseEventT& event, - FnT&& visitor, - fn_return_t<FnT>&& - defaultValue = {}) +visit(const BaseEventT& event, FnT&& visitor, + fn_return_t<FnT>&& defaultValue = {}) { using event_type = fn_arg_t<FnT>; if (is<std::decay_t<event_type>>(event)) |