diff --git a/js/ui/screenShield.js b/js/ui/screenShield.js index 03e457c90..6aef53b1a 100644 --- a/js/ui/screenShield.js +++ b/js/ui/screenShield.js @@ -1335,6 +1335,8 @@ const ScreenShield = new Lang.Class({ // If the previous shell crashed, and gnome-session restarted us, then re-lock lockIfWasLocked: function() { + if (!this._settings.get_boolean(LOCK_ENABLED_KEY)) + return; let wasLocked = global.get_runtime_state('b', LOCKED_STATE_STR); if (wasLocked === null) return;