From 0c766a100e416611807a184ee35a0edbd11b15a4 Mon Sep 17 00:00:00 2001 From: Janne Heß Date: Wed, 16 Jun 2021 12:27:47 +0200 Subject: lib/options: Throw error for options without a type Makes all options rendered in the manual throw an error if they don't have a type specified. This is a follow-up to #76184 Co-Authored-By: Silvan Mosberger --- lib/options.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/options.nix b/lib/options.nix index 627aac24d2f..9efc1249e58 100644 --- a/lib/options.nix +++ b/lib/options.nix @@ -231,7 +231,7 @@ rec { then true else opt.visible or true; readOnly = opt.readOnly or false; - type = opt.type.description or null; + type = opt.type.description or "unspecified"; } // optionalAttrs (opt ? example) { example = scrubOptionValue opt.example; } // optionalAttrs (opt ? default) { default = scrubOptionValue opt.default; } -- cgit 1.4.1