summary refs log tree commit diff
path: root/nixos/modules/hardware/video/nvidia.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixos/modules/hardware/video/nvidia.nix')
-rw-r--r--nixos/modules/hardware/video/nvidia.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/hardware/video/nvidia.nix b/nixos/modules/hardware/video/nvidia.nix
index 5b379505608..ff4225dc29a 100644
--- a/nixos/modules/hardware/video/nvidia.nix
+++ b/nixos/modules/hardware/video/nvidia.nix
@@ -179,7 +179,7 @@ in
   in mkIf enabled {
     assertions = [
       {
-        assertion = with config.services.xserver.displayManager; gdm.nvidiaWayland -> cfg.modesetting.enable;
+        assertion = with config.services.xserver.displayManager; (gdm.enable && gdm.nvidiaWayland) -> cfg.modesetting.enable;
         message = "You cannot use wayland with GDM without modesetting enabled for NVIDIA drivers, set `hardware.nvidia.modesetting.enable = true`";
       }