fix: log deletion messages to file log (#6465)
This commit is contained in:
@@ -8,6 +8,7 @@
|
|||||||
- Bugfix: Fixed flickering tooltips on Wayland when the mouse cursor is over them. (#6451)
|
- Bugfix: Fixed flickering tooltips on Wayland when the mouse cursor is over them. (#6451)
|
||||||
- Bugfix: Fixed `c2.Channel` comparing `false` to the same channel. (#6456)
|
- Bugfix: Fixed `c2.Channel` comparing `false` to the same channel. (#6456)
|
||||||
- Bugfix: Fixed an issue where the moderation icon was missing from the Moderation tab. (#6457)
|
- Bugfix: Fixed an issue where the moderation icon was missing from the Moderation tab. (#6457)
|
||||||
|
- Bugfix: Fixed "_A message from X has been deleted_" messages logging empty messages to disk. (#6465)
|
||||||
- Bugfix: Do not set default hotkeys for focusing splits on macOS, as <kbd>Option</kbd> + <kbd>Arrows</kbd> are used for cursor navigation. (#6470)
|
- Bugfix: Do not set default hotkeys for focusing splits on macOS, as <kbd>Option</kbd> + <kbd>Arrows</kbd> are used for cursor navigation. (#6470)
|
||||||
- Bugfix: Fixed <kbd>CMD</kbd>+<kbd>Backspace</kbd> not working in the input on macOS if there was a selection. (#6469)
|
- Bugfix: Fixed <kbd>CMD</kbd>+<kbd>Backspace</kbd> not working in the input on macOS if there was a selection. (#6469)
|
||||||
- Dev: Added documentation for WebSockets to `wip-plugins.md`. (#6432)
|
- Dev: Added documentation for WebSockets to `wip-plugins.md`. (#6432)
|
||||||
|
|||||||
@@ -1255,22 +1255,25 @@ MessagePtr MessageBuilder::makeDeletionMessageFromIRC(
|
|||||||
->setLink({Link::UserInfo, originalMessage->loginName});
|
->setLink({Link::UserInfo, originalMessage->loginName});
|
||||||
builder.emplace<TextElement>("was deleted:", MessageElementFlag::Text,
|
builder.emplace<TextElement>("was deleted:", MessageElementFlag::Text,
|
||||||
MessageColor::System);
|
MessageColor::System);
|
||||||
if (originalMessage->messageText.length() > 50)
|
|
||||||
|
auto deletedMessageText = originalMessage->messageText;
|
||||||
|
if (deletedMessageText.length() > 50)
|
||||||
{
|
{
|
||||||
builder
|
deletedMessageText = deletedMessageText.left(50) + "…";
|
||||||
.emplace<TextElement>(originalMessage->messageText.left(50) + "…",
|
|
||||||
MessageElementFlag::Text, MessageColor::Text)
|
|
||||||
->setLink({Link::JumpToMessage, originalMessage->id});
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
builder
|
|
||||||
.emplace<TextElement>(originalMessage->messageText,
|
|
||||||
MessageElementFlag::Text, MessageColor::Text)
|
|
||||||
->setLink({Link::JumpToMessage, originalMessage->id});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
builder
|
||||||
|
.emplace<TextElement>(deletedMessageText, MessageElementFlag::Text,
|
||||||
|
MessageColor::Text)
|
||||||
|
->setLink({Link::JumpToMessage, originalMessage->id});
|
||||||
builder.message().timeoutUser = "msg:" + originalMessage->id;
|
builder.message().timeoutUser = "msg:" + originalMessage->id;
|
||||||
|
|
||||||
|
const auto deletionText =
|
||||||
|
QString("A message from %1 was deleted: %2")
|
||||||
|
.arg(originalMessage->loginName, deletedMessageText);
|
||||||
|
builder.message().messageText = deletionText;
|
||||||
|
builder.message().searchText = deletionText;
|
||||||
|
|
||||||
return builder.release();
|
return builder.release();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,122 @@
|
|||||||
|
{
|
||||||
|
"input": "@tmi-sent-ts=1757929420105;room-id=111448817;target-msg-id=862716db-9a7c-4563-8480-af799769ae81;rm-received-ts=1757929420186;login=kooby_ :tmi.twitch.tv CLEARMSG #pajlada sup",
|
||||||
|
"output": [
|
||||||
|
{
|
||||||
|
"badgeInfos": {
|
||||||
|
},
|
||||||
|
"badges": [
|
||||||
|
],
|
||||||
|
"channelName": "",
|
||||||
|
"count": 1,
|
||||||
|
"displayName": "",
|
||||||
|
"elements": [
|
||||||
|
{
|
||||||
|
"element": {
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Timestamp",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"style": "TimestampMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"0:00"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"flags": "Timestamp",
|
||||||
|
"format": "",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"time": "00:00:00",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TimestampElement"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Text",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"style": "ChatMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"A",
|
||||||
|
"message",
|
||||||
|
"from"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Username",
|
||||||
|
"link": {
|
||||||
|
"type": "UserInfo",
|
||||||
|
"value": "kooby_"
|
||||||
|
},
|
||||||
|
"style": "ChatMediumBold",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"KOOBY_"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Text",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"style": "ChatMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"was",
|
||||||
|
"deleted:"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "Text",
|
||||||
|
"flags": "Text",
|
||||||
|
"link": {
|
||||||
|
"type": "JumpToMessage",
|
||||||
|
"value": "862716db-9a7c-4563-8480-af799769ae81"
|
||||||
|
},
|
||||||
|
"style": "ChatMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"sup"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"flags": "System|DoNotTriggerNotification|ModerationAction",
|
||||||
|
"frozen": false,
|
||||||
|
"id": "",
|
||||||
|
"localizedName": "",
|
||||||
|
"loginName": "",
|
||||||
|
"messageText": "A message from kooby_ was deleted: sup",
|
||||||
|
"searchText": "A message from kooby_ was deleted: sup",
|
||||||
|
"serverReceivedTime": "",
|
||||||
|
"timeoutUser": "msg:862716db-9a7c-4563-8480-af799769ae81",
|
||||||
|
"userID": "",
|
||||||
|
"usernameColor": "#ff000000"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"params": {
|
||||||
|
"prevMessages": [
|
||||||
|
"@display-name=KOOBY_;rm-received-ts=1757929402936;returning-chatter=0;historical=1;turbo=0;badges=no_audio/1;mod=0;subscriber=0;user-type=;flags=;room-id=11148817;badge-info=;color=#B9CCED;emotes=;id=862716db-9a7c-4563-8480-af799769ae81;first-msg=0;user-id=71642781;rm-deleted=1;tmi-sent-ts=1757929402746 :kooby_!kooby_@kooby_.tmi.twitch.tv PRIVMSG #pajlada sup"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,131 @@
|
|||||||
|
{
|
||||||
|
"input": "@rm-received-ts=1757929422007;login=kooby_;room-id=111448817;tmi-sent-ts=1757929421924;target-msg-id=ee436bee-aaac-49db-9a87-755c29105f6a :tmi.twitch.tv CLEARMSG #pajlada :Hello! its me Winston! Go to your fridge and stuff your big belly with food. I need you big and fat. FAT. FATTER. FATTER... FATTER! I need you to gain weight and get bulbous.",
|
||||||
|
"output": [
|
||||||
|
{
|
||||||
|
"badgeInfos": {
|
||||||
|
},
|
||||||
|
"badges": [
|
||||||
|
],
|
||||||
|
"channelName": "",
|
||||||
|
"count": 1,
|
||||||
|
"displayName": "",
|
||||||
|
"elements": [
|
||||||
|
{
|
||||||
|
"element": {
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Timestamp",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"style": "TimestampMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"0:00"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"flags": "Timestamp",
|
||||||
|
"format": "",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"time": "00:00:00",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TimestampElement"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Text",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"style": "ChatMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"A",
|
||||||
|
"message",
|
||||||
|
"from"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Username",
|
||||||
|
"link": {
|
||||||
|
"type": "UserInfo",
|
||||||
|
"value": "kooby_"
|
||||||
|
},
|
||||||
|
"style": "ChatMediumBold",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"KOOBY_"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "System",
|
||||||
|
"flags": "Text",
|
||||||
|
"link": {
|
||||||
|
"type": "None",
|
||||||
|
"value": ""
|
||||||
|
},
|
||||||
|
"style": "ChatMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"was",
|
||||||
|
"deleted:"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"color": "Text",
|
||||||
|
"flags": "Text",
|
||||||
|
"link": {
|
||||||
|
"type": "JumpToMessage",
|
||||||
|
"value": "ee436bee-aaac-49db-9a87-755c29105f6a"
|
||||||
|
},
|
||||||
|
"style": "ChatMedium",
|
||||||
|
"tooltip": "",
|
||||||
|
"trailingSpace": true,
|
||||||
|
"type": "TextElement",
|
||||||
|
"words": [
|
||||||
|
"Hello!",
|
||||||
|
"its",
|
||||||
|
"me",
|
||||||
|
"Winston!",
|
||||||
|
"Go",
|
||||||
|
"to",
|
||||||
|
"your",
|
||||||
|
"fridge",
|
||||||
|
"and",
|
||||||
|
"stuff…"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"flags": "System|DoNotTriggerNotification|ModerationAction",
|
||||||
|
"frozen": false,
|
||||||
|
"id": "",
|
||||||
|
"localizedName": "",
|
||||||
|
"loginName": "",
|
||||||
|
"messageText": "A message from kooby_ was deleted: Hello! its me Winston! Go to your fridge and stuff…",
|
||||||
|
"searchText": "A message from kooby_ was deleted: Hello! its me Winston! Go to your fridge and stuff…",
|
||||||
|
"serverReceivedTime": "",
|
||||||
|
"timeoutUser": "msg:ee436bee-aaac-49db-9a87-755c29105f6a",
|
||||||
|
"userID": "",
|
||||||
|
"usernameColor": "#ff000000"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"params": {
|
||||||
|
"prevMessages": [
|
||||||
|
"@tmi-sent-ts=1757929410864;user-type=;room-id=11148817;mod=0;user-id=71642781;flags=;rm-received-ts=1757929411035;historical=1;subscriber=0;display-name=KOOBY_;id=ee436bee-aaac-49db-9a87-755c29105f6a;badge-info=;color=#B9CCED;emotes=;turbo=0;rm-deleted=1;first-msg=0;returning-chatter=0;badges=no_audio/1 :kooby_!kooby_@kooby_.tmi.twitch.tv PRIVMSG #pajlada :Hello! its me Winston! Go to your fridge and stuff your big belly with food. I need you big and fat. FAT. FATTER. FATTER... FATTER! I need you to gain weight and get bulbous."
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user