Commit bf2d0ece authored by Arjen Hiemstra's avatar Arjen Hiemstra
Browse files

Prevent inadvertently writing config when destroying SensorFaceController

In certain cases, we may end up with a dirty config which we do not want
to store. So explicitly cleanup the config objects before destruction to
prevent them from being written.

parent ae21f67c
......@@ -386,6 +386,16 @@ SensorFaceController::SensorFaceController(KConfigGroup &config, QQmlEngine *eng
if (!d->shouldSync) {
// If we should not sync automatically, clear all changes before we
// destroy the config objects, otherwise they will be written during
// destruction.
if (d->faceConfigLoader->isSaveNeeded()) {
QString SensorFaceController::title() const
Supports Markdown
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