From 7580a250182df61111226e3dc6e48ff9eb4de69d Mon Sep 17 00:00:00 2001 From: Pi3r Date: Mon, 1 Sep 2014 13:53:08 +0200 Subject: [PATCH] cosmetic: default in last position The main motivation for this change is for compatibility with puppetresource (https://github.com/bartavelle/language-puppet). IMHO, it makes much more sense this way because all cases are checked order wise. --- manifests/params.pp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/manifests/params.pp b/manifests/params.pp index 865ebd0..aeedea7 100644 --- a/manifests/params.pp +++ b/manifests/params.pp @@ -13,10 +13,8 @@ class java::params { case $::osfamily { - default: { fail("unsupported platform ${::osfamily}") } 'RedHat': { case $::operatingsystem { - default: { fail("unsupported os ${::operatingsystem}") } 'RedHat', 'CentOS', 'OracleLinux', 'Scientific': { if (versioncmp($::operatingsystemrelease, '5.0') < 0) { $jdk_package = 'java-1.6.0-sun-devel' @@ -39,6 +37,7 @@ class java::params { $jdk_package = 'java-1.7.0-openjdk-devel' $jre_package = 'java-1.7.0-openjdk' } + default: { fail("unsupported os ${::operatingsystem}") } } $java = { 'jdk' => { 'package' => $jdk_package, }, @@ -129,5 +128,6 @@ class java::params { 'jre' => { 'package' => $jre_package, }, } } + default: { fail("unsupported platform ${::osfamily}") } } }