Replace default to be more robust
authorDavid Gurtner <aldavud@crimson.ch>
Mon, 20 Feb 2017 17:50:54 +0000 (18:50 +0100)
committerDavid Gurtner <aldavud@crimson.ch>
Mon, 20 Feb 2017 18:03:08 +0000 (19:03 +0100)
Specifying undef as the fallback only works because the merge
function specifically checks for this:
next if arg.is_a? String and arg.empty? # empty string is synonym for puppet's undef

But the empty Hash would be a much more robust default.

Change-Id: I7e302c00ef030d75998e352d88b3ccc60b194ab7

manifests/profile/base/horizon.pp

index 1849435..278c25c 100644 (file)
 #
 # [*neutron_options*]
 #   (Optional) A hash of parameters to enable features specific to Neutron
-#   Defaults to hiera('horizon::neutron_options', undef)
+#   Defaults to hiera('horizon::neutron_options', {})
 #
 class tripleo::profile::base::horizon (
   $step            = hiera('step'),
-  $neutron_options = hiera('horizon::neutron_options', undef),
+  $neutron_options = hiera('horizon::neutron_options', {}),
 ) {
   if $step >= 4 {
     # Horizon