I don't see why this would have detached, but make clazy happy
This commit is contained in:
parent
8730586cfd
commit
eefa6379f9
@ -42,7 +42,8 @@ MxcImageProvider::MxcImageProvider(QObject *parent)
|
|||||||
QDir::SortFlags(QDir::Name | QDir::IgnoreCase),
|
QDir::SortFlags(QDir::Name | QDir::IgnoreCase),
|
||||||
QDir::Filter::Writable | QDir::Filter::NoDotAndDotDot | QDir::Filter::Files);
|
QDir::Filter::Writable | QDir::Filter::NoDotAndDotDot | QDir::Filter::Files);
|
||||||
|
|
||||||
for (const auto &fileInfo : dir.entryInfoList()) {
|
auto files = dir.entryInfoList();
|
||||||
|
for (const auto &fileInfo : qAsConst(files)) {
|
||||||
if (fileInfo.fileTime(QFile::FileTime::FileAccessTime)
|
if (fileInfo.fileTime(QFile::FileTime::FileAccessTime)
|
||||||
.daysTo(QDateTime::currentDateTime()) > 30) {
|
.daysTo(QDateTime::currentDateTime()) > 30) {
|
||||||
if (QFile::remove(fileInfo.absoluteFilePath()))
|
if (QFile::remove(fileInfo.absoluteFilePath()))
|
||||||
|
Loading…
Reference in New Issue
Block a user