diff --git a/src/timeline/EventStore.cpp b/src/timeline/EventStore.cpp
index 78920ac4..8e244f42 100644
--- a/src/timeline/EventStore.cpp
+++ b/src/timeline/EventStore.cpp
@@ -16,6 +16,7 @@
#include "EventAccessors.h"
#include "Logging.h"
#include "MatrixClient.h"
+#include "UserSettingsPage.h"
#include "Utils.h"
Q_DECLARE_METATYPE(Reaction)
@@ -220,11 +221,14 @@ EventStore::EventStore(std::string room_id, QObject *)
}
http::client()->read_event(
- room_id_, event_id, [this, event_id](mtx::http::RequestErr err) {
+ room_id_,
+ event_id,
+ [this, event_id](mtx::http::RequestErr err) {
if (err) {
nhlog::net()->warn("failed to read_event ({}, {})", room_id_, event_id);
}
- });
+ },
+ !UserSettings::instance()->readReceipts());
auto idx = idToIndex(event_id);
diff --git a/src/timeline/TimelineModel.cpp b/src/timeline/TimelineModel.cpp
index fe92fcf7..64cff6b8 100644
--- a/src/timeline/TimelineModel.cpp
+++ b/src/timeline/TimelineModel.cpp
@@ -1077,12 +1077,16 @@ TimelineModel::setCurrentIndex(int index)
void
TimelineModel::readEvent(const std::string &id)
{
- http::client()->read_event(room_id_.toStdString(), id, [this](mtx::http::RequestErr err) {
- if (err) {
- nhlog::net()->warn(
- "failed to read_event ({}, {})", room_id_.toStdString(), currentId.toStdString());
- }
- });
+ http::client()->read_event(
+ room_id_.toStdString(),
+ id,
+ [this](mtx::http::RequestErr err) {
+ if (err) {
+ nhlog::net()->warn(
+ "failed to read_event ({}, {})", room_id_.toStdString(), currentId.toStdString());
+ }
+ },
+ !UserSettings::instance()->readReceipts());
}
QString
|