aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/QuickMedia.cpp2
-rw-r--r--src/plugins/Matrix.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/QuickMedia.cpp b/src/QuickMedia.cpp
index 04638f0..a7d9f49 100644
--- a/src/QuickMedia.cpp
+++ b/src/QuickMedia.cpp
@@ -6763,7 +6763,7 @@ namespace QuickMedia {
const char *music_prefix = "🎵 Play ";
const char *file_prefix = "💾 Download ";
- std::string filename = selected_item_message->body;
+ std::string filename = remove_reply_formatting(matrix, selected_item_message);
if(string_starts_with(filename, video_prefix))
filename.erase(filename.begin(), filename.begin() + strlen(video_prefix));
else if(string_starts_with(filename, music_prefix))
diff --git a/src/plugins/Matrix.cpp b/src/plugins/Matrix.cpp
index 9dd4ec9..13c6f4f 100644
--- a/src/plugins/Matrix.cpp
+++ b/src/plugins/Matrix.cpp
@@ -298,7 +298,7 @@ namespace QuickMedia {
return str;
}
- static std::string remove_reply_formatting(Matrix *matrix, const Message *message, bool keep_formatted = false) {
+ std::string remove_reply_formatting(Matrix *matrix, const Message *message, bool keep_formatted) {
if(!message->body_is_formatted && strncmp(message->body.c_str(), "> <@", 4) == 0) {
size_t index = message->body.find("> ", 4);
if(index != std::string::npos) {