Corrected the way we parse comma-separated "list tags" in PRIVMSGs (#3771)
tl;dr: we now split by slash only its first occurrence instead of every occurrence.
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
#include "common/Aliases.hpp"
|
||||
#include "common/Outcome.hpp"
|
||||
#include "messages/MessageColor.hpp"
|
||||
#include "providers/twitch/TwitchBadge.hpp"
|
||||
|
||||
#include <IrcMessage>
|
||||
#include <QColor>
|
||||
@@ -32,6 +33,11 @@ public:
|
||||
virtual void triggerHighlights();
|
||||
virtual MessagePtr build() = 0;
|
||||
|
||||
static std::pair<QString, QString> slashKeyValue(const QString &kvStr);
|
||||
|
||||
// Parses "badges" tag which contains a comma separated list of key-value elements
|
||||
static std::vector<Badge> parseBadgeTag(const QVariantMap &tags);
|
||||
|
||||
protected:
|
||||
virtual void parse();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user