From 4f8e4d11e51e2436b957157de86755f5f8879f61 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Fri, 18 Dec 2020 22:47:10 +0100 Subject: Matrix: get previous messages immediately even if sync in progress --- src/plugins/Matrix.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/plugins/Matrix.cpp') diff --git a/src/plugins/Matrix.cpp b/src/plugins/Matrix.cpp index 003cf46..a07d050 100644 --- a/src/plugins/Matrix.cpp +++ b/src/plugins/Matrix.cpp @@ -2355,7 +2355,7 @@ namespace QuickMedia { PluginResult Matrix::get_previous_room_messages(RoomData *room_data, bool latest_messages, size_t &num_new_messages) { num_new_messages = 0; std::string from = room_data->get_prev_batch(); - if(from.empty()) + if(from.empty() || latest_messages) from = "END"; rapidjson::Document request_data(rapidjson::kObjectType); -- cgit v1.2.3