Some syntax things
authorStephen Gran <steve@lobefin.net>
Fri, 22 May 2009 23:33:38 +0000 (00:33 +0100)
committerStephen Gran <steve@lobefin.net>
Fri, 22 May 2009 23:33:38 +0000 (00:33 +0100)
Signed-off-by: Stephen Gran <steve@lobefin.net>
files/etc/puppet/lib/puppet/parser/functions/nodeinfo.rb
modules/exim/templates/eximconf.erb

index 64e94db..84e5bc9 100644 (file)
@@ -31,7 +31,7 @@ module Puppet::Parser::Functions
 
     results['mail_port']      = ''
     results['smarthost']      = ''
-    results['heavy_exim']     = ""
+    results['heavy_exim']     = ''
     results['smarthost_port'] = 587
     results['reservedaddrs']  = '0.0.0.0/8 : 127.0.0.0/8 : 10.0.0.0/8 : 169.254.0.0/16 : 172.16.0.0/12 : 192.0.0.0/17 : 192.168.0.0/16 : 224.0.0.0/4 : 240.0.0.0/5 : 248.0.0.0/5'
 
index b5c4d4e..be08938 100644 (file)
@@ -86,7 +86,7 @@ out
 
 <%=
 out=''
-if not nodeinfo['heavy_exim'].empty?
+if nodeinfo.has_key?('heavy_exim') and not nodeinfo['heavy_exim'].empty?
   out = "
 perl_startup = do '/etc/exim4/exim_surbl.pl'
 "
@@ -836,7 +836,7 @@ out
 
 <%=
 out=''
-if not nodeinfo['heavy_exim'].empty?
+if nodeinfo.has_key?('heavy_exim') and not nodeinfo['heavy_exim'].empty?
 out='
   deny   condition     = ${if <{$message_size}{256000}}
          set acl_m5    = ${perl{surblspamcheck}}