mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-11 15:27:54 +00:00
Don't use white spaces as separator in RSS "must not contain" rules
This RegExp uses both white spaces and | as separator. Use only the latter and drop the RegExp as it is no longer required.
This commit is contained in:
parent
5dede9e433
commit
c6dbe8ea60
@ -605,7 +605,7 @@ void AutomatedRssDownloader::updateMustNotLineValidity()
|
|||||||
if (ui->checkRegex->isChecked())
|
if (ui->checkRegex->isChecked())
|
||||||
tokens << text;
|
tokens << text;
|
||||||
else
|
else
|
||||||
tokens << text.split(QRegExp("[\\s|]"));
|
tokens << text.split("|");
|
||||||
foreach (const QString &token, tokens) {
|
foreach (const QString &token, tokens) {
|
||||||
QRegExp reg(token, Qt::CaseInsensitive, ui->checkRegex->isChecked() ? QRegExp::RegExp : QRegExp::Wildcard);
|
QRegExp reg(token, Qt::CaseInsensitive, ui->checkRegex->isChecked() ? QRegExp::RegExp : QRegExp::Wildcard);
|
||||||
if (!reg.isValid()) {
|
if (!reg.isValid()) {
|
||||||
|
@ -133,7 +133,7 @@ void RssDownloadRule::setMustNotContain(const QString &tokens)
|
|||||||
if (m_useRegex)
|
if (m_useRegex)
|
||||||
m_mustNotContain = QStringList() << tokens;
|
m_mustNotContain = QStringList() << tokens;
|
||||||
else
|
else
|
||||||
m_mustNotContain = tokens.split(QRegExp("[\\s|]"));
|
m_mustNotContain = tokens.split("|");
|
||||||
}
|
}
|
||||||
|
|
||||||
RssDownloadRulePtr RssDownloadRule::fromVariantHash(const QVariantHash &rule_hash)
|
RssDownloadRulePtr RssDownloadRule::fromVariantHash(const QVariantHash &rule_hash)
|
||||||
|
Loading…
Reference in New Issue
Block a user