nixos/gdm: simplify assert expression

This commit is contained in:
Bjørn Forsman 2015-09-05 10:21:43 +02:00
parent f2271f7c19
commit 41ae7e00d7

View File

@ -69,8 +69,7 @@ in
config = mkIf cfg.gdm.enable {
assertions = [
{ assertion = let autoLogin = cfg.gdm.autoLogin; in
if autoLogin.enable then autoLogin.user != null else true;
{ assertion = cfg.gdm.autoLogin.enable -> cfg.gdm.autoLogin.user != null;
message = "GDM auto-login requires services.xserver.displayManager.gdm.autoLogin.user to be set";
}
];