Skip to content

Commit

Permalink
options: fix uninstallUnmanaged default value.
Browse files Browse the repository at this point in the history
Coherce `null` value to `false` when initialising
the value of uninstallUnmanaged from the
uninstallUnmanagedPackages option default
value.

Fixes issue #61.
  • Loading branch information
gmodena committed Apr 1, 2024
1 parent 248912b commit 9e68bdb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modules/options.nix
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,8 @@ in

uninstallUnmanaged = mkOption {
type = with types; bool;
default = config.services.flatpak.uninstallUnmanagedPackages || false;
default = (if isNull config.services.flatpak.uninstallUnmanagedPackages then false else
config.services.flatpak.uninstallUnmanagedPackages) || false;
description = lib.mdDoc ''
If enabled, uninstall packages and delete remotes not managed by this module on activation.
I.e. if packages were installed via Flatpak directly instead of this module,
Expand Down

0 comments on commit 9e68bdb

Please sign in to comment.