Skip to content

Instantly share code, notes, and snippets.

@richm
Created December 4, 2014 22:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save richm/21474ce1671336eec931 to your computer and use it in GitHub Desktop.
Save richm/21474ce1671336eec931 to your computer and use it in GitHub Desktop.
class fooclass (
$foo = "using default"
) {
warning("foo = [$foo]")
}
class { 'fooclass': foo => hiera('does not exist', undef) }
# This prints Warning: foo = []
class fooclass (
$foo = "using default"
) {
warning("foo = [$foo]")
}
class { 'fooclass': foo => undef }
# This prints Warning: foo = [using default]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment