cmake: avoid de-duplication of user's CXXFLAGS
[quassel.git] / src / common / ignorelistmanager.cpp
index 3d9ae5f..1095681 100644 (file)
@@ -1,5 +1,5 @@
 /***************************************************************************
- *   Copyright (C) 2005-2018 by the Quassel Project                        *
+ *   Copyright (C) 2005-2022 by the Quassel Project                        *
  *   devel@quassel-irc.org                                                 *
  *                                                                         *
  *   This program is free software; you can redistribute it and/or modify  *
 
 #include <QDebug>
 #include <QStringList>
-#include <QtCore>
 
-IgnoreListManager& IgnoreListManager::operator=(const IgnoreListManager& other)
-{
-    if (this == &other)
-        return *this;
-
-    SyncableObject::operator=(other);
-    _ignoreList = other._ignoreList;
-    return *this;
-}
+#include "util.h"
 
 int IgnoreListManager::indexOf(const QString& ignore) const
 {
@@ -142,10 +133,12 @@ IgnoreListManager::StrictnessType IgnoreListManager::_match(
         if (item.scope() == GlobalScope || (item.scope() == NetworkScope && item.scopeRuleMatcher().match(network))
             || (item.scope() == ChannelScope && item.scopeRuleMatcher().match(bufferName))) {
             QString str;
-            if (item.type() == MessageIgnore)
-                str = msgContents;
-            else
+            if (item.type() == MessageIgnore) {
+                // TODO: Make this configurable?  Pre-0.14, format codes were not removed
+                str = stripFormatCodes(msgContents);
+            } else {
                 str = msgSender;
+            }
 
             //      qDebug() << "IgnoreListManager::match: ";
             //      qDebug() << "string: " << str;