aboutsummaryrefslogtreecommitdiff
path: root/lib/events
diff options
context:
space:
mode:
Diffstat (limited to 'lib/events')
-rw-r--r--lib/events/directchatevent.cpp2
-rw-r--r--lib/events/eventcontent.h2
-rw-r--r--lib/events/roomevent.cpp4
-rw-r--r--lib/events/stateevent.cpp4
4 files changed, 5 insertions, 7 deletions
diff --git a/lib/events/directchatevent.cpp b/lib/events/directchatevent.cpp
index 0ee1f7b0..83bb1e32 100644
--- a/lib/events/directchatevent.cpp
+++ b/lib/events/directchatevent.cpp
@@ -3,8 +3,6 @@
#include "directchatevent.h"
-#include <QtCore/QJsonArray>
-
using namespace Quotient;
QMultiHash<QString, QString> DirectChatEvent::usersToDirectChats() const
diff --git a/lib/events/eventcontent.h b/lib/events/eventcontent.h
index 6aee333d..bbd35618 100644
--- a/lib/events/eventcontent.h
+++ b/lib/events/eventcontent.h
@@ -40,7 +40,7 @@ namespace EventContent {
Base(const Base&) = default;
Base(Base&&) = default;
- virtual void fillJson(QJsonObject& o) const = 0;
+ virtual void fillJson(QJsonObject&) const = 0;
};
// The below structures fairly follow CS spec 11.2.1.6. The overall
diff --git a/lib/events/roomevent.cpp b/lib/events/roomevent.cpp
index 707cf4fd..3ddf5ac4 100644
--- a/lib/events/roomevent.cpp
+++ b/lib/events/roomevent.cpp
@@ -103,7 +103,7 @@ void RoomEvent::dumpTo(QDebug dbg) const
QJsonObject CallEventBase::basicJson(const QString& matrixType,
const QString& callId, int version,
- QJsonObject content)
+ QJsonObject contentJson)
{
contentJson.insert(QStringLiteral("call_id"), callId);
contentJson.insert(QStringLiteral("version"), version);
@@ -116,7 +116,7 @@ CallEventBase::CallEventBase(Type type, event_mtype_t matrixType,
: RoomEvent(type, basicJson(matrixType, callId, version, contentJson))
{}
-CallEventBase::CallEventBase(Event::Type type, const QJsonObject& json)
+CallEventBase::CallEventBase(Type type, const QJsonObject& json)
: RoomEvent(type, json)
{
if (callId().isEmpty())
diff --git a/lib/events/stateevent.cpp b/lib/events/stateevent.cpp
index 0fd489d1..c343e37f 100644
--- a/lib/events/stateevent.cpp
+++ b/lib/events/stateevent.cpp
@@ -6,9 +6,9 @@
using namespace Quotient;
StateEventBase::StateEventBase(Type type, const QJsonObject& json)
- : RoomEvent(json.contains(StateKeyKeyL) ? type : unknownEventTypeId(), json)
+ : RoomEvent(json.contains(StateKeyKeyL) ? type : UnknownEventTypeId, json)
{
- if (Event::type() == unknownEventTypeId() && !json.contains(StateKeyKeyL))
+ if (Event::type() == UnknownEventTypeId && !json.contains(StateKeyKeyL))
qWarning(EVENTS) << "Attempt to create a state event with no stateKey -"
"forcing the event type to unknown to avoid damage";
}