From 39b980df2522d0e8d7fe91f3b6650dcb9490b485 Mon Sep 17 00:00:00 2001 From: David Schmitt Date: Fri, 29 Feb 2008 16:49:59 +0100 Subject: [PATCH] config_file: use File's built-in checking for content/source --- manifests/defines/config_file.pp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/manifests/defines/config_file.pp b/manifests/defines/config_file.pp index 3e6bc06..cd6ccc3 100644 --- a/manifests/defines/config_file.pp +++ b/manifests/defines/config_file.pp @@ -38,13 +38,13 @@ define config_file ($content = '', $source = '', $ensure = 'present') { checksum => md5, } + case $source { + '': { } + default: { File[$name] { source => $source } } + } + case $content { - '': { - case $source { - '': { } - default: { File[$name] { source => $source } } - } - } + '': { } default: { File[$name] { content => $content } } }