summaryrefslogtreecommitdiffstats
path: root/common/resourcefacade.cpp
diff options
context:
space:
mode:
authorChristian Mollekopf <chrigi_1@fastmail.fm>2015-12-22 16:36:37 +0100
committerChristian Mollekopf <chrigi_1@fastmail.fm>2015-12-22 16:36:37 +0100
commitf08eb59a2c752fdbed54c34809d4d6664a4cd81f (patch)
tree9f9a430a28b11c6dd843f7d1e2031ede498657e6 /common/resourcefacade.cpp
parente8ab53258c044969146be385629a80afe801dee5 (diff)
downloadsink-f08eb59a2c752fdbed54c34809d4d6664a4cd81f.tar.gz
sink-f08eb59a2c752fdbed54c34809d4d6664a4cd81f.zip
Remove all resource data with the resource.
Diffstat (limited to 'common/resourcefacade.cpp')
-rw-r--r--common/resourcefacade.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/common/resourcefacade.cpp b/common/resourcefacade.cpp
index df52538..2e4d668 100644
--- a/common/resourcefacade.cpp
+++ b/common/resourcefacade.cpp
@@ -87,6 +87,11 @@ KAsync::Job<void> ResourceFacade::remove(const Akonadi2::ApplicationDomain::Akon
87 return; 87 return;
88 } 88 }
89 ResourceConfig::removeResource(identifier); 89 ResourceConfig::removeResource(identifier);
90 //TODO shutdown resource, or use the resource process with a --remove option to cleanup (so we can take advantage of the file locking)
91 QDir dir(Akonadi2::storageLocation());
92 for (const auto &folder : dir.entryList(QStringList() << identifier + "*")) {
93 Akonadi2::Storage(Akonadi2::storageLocation(), folder, Akonadi2::Storage::ReadWrite).removeFromDisk();
94 }
90 }); 95 });
91} 96}
92 97