Commit 7360503f authored by Ahmad Samir's avatar Ahmad Samir Committed by Kurt Hindenburg
Browse files

Make UrlFilter::CompleteUrlRegExp match case-insensitively

Since it uses the pattern of UrlFilter::FullUrlRegExp, which should match
case-insensitively.
parent 40b1fcf4
Pipeline #182426 passed with stage
in 2 minutes and 19 seconds
......@@ -68,7 +68,7 @@ const QRegularExpression UrlFilter::FullUrlRegExp(
+ LS1(query)
+ LS1(fragment)
, QRegularExpression::CaseInsensitiveOption);
/* clang-format on */
/////////////////////////////////////////////
......@@ -77,9 +77,11 @@ const QRegularExpression UrlFilter::FullUrlRegExp(
const QRegularExpression UrlFilter::EmailAddressRegExp(QStringLiteral("\\b(\\w|\\.|-|\\+)+@(\\w|\\.|-)+\\.\\w+\\b"));
// matches full url or email address
const QRegularExpression UrlFilter::CompleteUrlRegExp(QLatin1Char('(') + FullUrlRegExp.pattern() + QLatin1Char('|') + EmailAddressRegExp.pattern()
+ QLatin1Char(')'));
const QRegularExpression UrlFilter::CompleteUrlRegExp(
QLatin1Char('(') + FullUrlRegExp.pattern() + QLatin1Char('|') + EmailAddressRegExp.pattern()+ QLatin1Char(')'),
QRegularExpression::CaseInsensitiveOption);
/* clang-format on */
UrlFilter::UrlFilter()
{
setRegExp(CompleteUrlRegExp);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment