Add delay before processing FS changes

This prevents file renaming errors in monitored folder on linux, for
example: ABC.torrent.part -> ABC.torrent
This commit is contained in:
Chocobo1 2018-03-14 14:24:44 +08:00
parent 19c733ce95
commit ea7eb7c0ec
No known key found for this signature in database
GPG Key ID: 210D9C873253A68C

View File

@ -124,7 +124,7 @@ void FileSystemWatcher::removePath(const QString &path)
void FileSystemWatcher::scanLocalFolder(const QString &path)
{
processTorrentsInDir(path);
QTimer::singleShot(2000, this, [this, path]() { processTorrentsInDir(path); });
}
#ifndef Q_OS_WIN