Add missing paranthesis
Not sure how these slipped through.
This commit is contained in:
parent
248bfb96fe
commit
01872e37d5
@ -277,7 +277,7 @@ LooqsQuery LooqsQuery::build(QString expression)
|
|||||||
throw LooqsGeneralException("Two sort statements are illegal");
|
throw LooqsGeneralException("Two sort statements are illegal");
|
||||||
}
|
}
|
||||||
// TODO: hack, since we are not a "filter", we must remove a preceeding (implicit) boolean
|
// TODO: hack, since we are not a "filter", we must remove a preceeding (implicit) boolean
|
||||||
if(result.tokens.last().type & BOOL == BOOL)
|
if((result.tokens.last().type & BOOL) == BOOL)
|
||||||
{
|
{
|
||||||
result.tokens.pop_back();
|
result.tokens.pop_back();
|
||||||
}
|
}
|
||||||
@ -292,7 +292,7 @@ LooqsQuery LooqsQuery::build(QString expression)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool contentsearch = result.getTokensMask() & FILTER_CONTENT == FILTER_CONTENT;
|
bool contentsearch = (result.getTokensMask() & FILTER_CONTENT) == FILTER_CONTENT;
|
||||||
bool sortsForContent = std::any_of(result.sortConditions.begin(), result.sortConditions.end(),
|
bool sortsForContent = std::any_of(result.sortConditions.begin(), result.sortConditions.end(),
|
||||||
[](SortCondition c) { return c.field == CONTENT_TEXT; });
|
[](SortCondition c) { return c.field == CONTENT_TEXT; });
|
||||||
|
|
||||||
|
@ -127,7 +127,7 @@ QSqlQuery SqliteSearch::makeSqlQuery(const LooqsQuery &query)
|
|||||||
QString whereSql;
|
QString whereSql;
|
||||||
QString joinSql;
|
QString joinSql;
|
||||||
QVector<QString> bindValues;
|
QVector<QString> bindValues;
|
||||||
bool isContentSearch = query.getTokensMask() & FILTER_CONTENT == FILTER_CONTENT;
|
bool isContentSearch = (query.getTokensMask() & FILTER_CONTENT) == FILTER_CONTENT;
|
||||||
if(query.getTokens().isEmpty())
|
if(query.getTokens().isEmpty())
|
||||||
{
|
{
|
||||||
throw LooqsGeneralException("Nothing to search for supplied");
|
throw LooqsGeneralException("Nothing to search for supplied");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user