From 2df7d4d63a3d1e788ee5a09b98b8dda2626e8bd1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20Hamb=C3=BCchen?= Date: Sun, 21 May 2017 15:03:16 +0200 Subject: [PATCH] manual: Fix `addCheck` example having arguments in wrong order. `addCheck` takes first the type, then the check. --- nixos/doc/manual/development/option-types.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/doc/manual/development/option-types.xml b/nixos/doc/manual/development/option-types.xml index 8e6ac53ad48..741e763c295 100644 --- a/nixos/doc/manual/development/option-types.xml +++ b/nixos/doc/manual/development/option-types.xml @@ -282,7 +282,7 @@ config.mod.two = { foo = 2; bar = "two"; }; byte = mkOption { description = "An integer between 0 and 255."; - type = addCheck (x: x >= 0 && x <= 255) types.int; + type = addCheck types.int (x: x >= 0 && x <= 255); }; Overriding a type