Commit 3a505301 authored by Martin Straka's avatar Martin Straka

Fixed wrong delete path for file provider

parent 0ad335b1
......@@ -278,14 +278,15 @@ QString getAndroidFileProviderBasePath(void) {
QString basePath = QStandardPaths::standardLocations(
QStandardPaths::AppDataLocation).value(0);
QDir dir(basePath);
QString fileProviderDir = basePath.append("/share_example_x_files");
QDir dir(fileProviderDir);
dir.removeRecursively();
QString documentsWorkPath = basePath.append("/share_example_x_files");
if (!QDir(documentsWorkPath).exists()) {
if (!QDir("").mkpath(documentsWorkPath)) {
if (!QDir(fileProviderDir).exists()) {
if (!QDir("").mkpath(fileProviderDir)) {
logErrorNL("Failed to create share directory: '%s'.",
documentsWorkPath.toUtf8().constData());
fileProviderDir.toUtf8().constData());
return QString();
}
}
......
Markdown is supported
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