Fix sub-module argument manipulation: Avoid using an empty set to check
the type of the module. svn path=/nixpkgs/trunk/; revision=17666
This commit is contained in:
parent
1a093f3b73
commit
c3d328ca48
|
@ -192,16 +192,13 @@ rec {
|
||||||
# locations to sub-options declarations
|
# locations to sub-options declarations
|
||||||
decls =
|
decls =
|
||||||
map (m:
|
map (m:
|
||||||
mapSubOptions (subModule:
|
mapSubOptions (subModule: (args:
|
||||||
let module = lib.applyIfFunction subModule {}; in
|
let module = lib.applyIfFunction subModule args; in
|
||||||
if lib.isModule module then
|
if lib.isModule module then
|
||||||
{ inherit (m) key; } // subModule
|
{ inherit (m) key; } // module
|
||||||
else
|
else
|
||||||
args: {
|
{ inherit (m) key; options = module; }
|
||||||
inherit (m) key;
|
)) m.options
|
||||||
options = lib.applyIfFunction subModule args;
|
|
||||||
}
|
|
||||||
) m.options
|
|
||||||
) (declarationsOf name);
|
) (declarationsOf name);
|
||||||
in
|
in
|
||||||
addOptionMakeUp
|
addOptionMakeUp
|
||||||
|
|
Loading…
Reference in New Issue