mirror of
https://github.com/nextcloud/desktop.git
synced 2024-10-25 13:55:47 +03:00
SyncJournal: Use the NOCASE Collate for blacklist query.
This commit is contained in:
parent
425d0d77c5
commit
04558beabe
1 changed files with 8 additions and 2 deletions
|
@ -272,9 +272,15 @@ bool SyncJournalDb::checkConnect()
|
|||
_deleteFileRecordRecursively.reset(new QSqlQuery(_db));
|
||||
_deleteFileRecordRecursively->prepare("DELETE FROM metadata WHERE path LIKE(?||'/%')");
|
||||
|
||||
_blacklistQuery.reset(new QSqlQuery(_db));
|
||||
_blacklistQuery->prepare("SELECT lastTryEtag, lastTryModtime, retrycount, errorstring "
|
||||
QString sql( "SELECT lastTryEtag, lastTryModtime, retrycount, errorstring "
|
||||
"FROM blacklist WHERE path=:path");
|
||||
if( Utility::fsCasePreserving() ) {
|
||||
// if the file system is case preserving we have to check the blacklist
|
||||
// case insensitively
|
||||
sql += QLatin1String(" COLLATE NOCASE");
|
||||
}
|
||||
_blacklistQuery.reset(new QSqlQuery(_db));
|
||||
_blacklistQuery->prepare(sql);
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue