From 5f73eb553fd083b558fb9553b0c07b6019d0ccee Mon Sep 17 00:00:00 2001 From: James Turnbull Date: Thu, 26 Feb 2009 11:43:39 +1100 Subject: Fixed #1849 - Ruby 1.9 portability: `when' doesn't like colons, replace with semicolons --- lib/puppet/file_serving/configuration/parser.rb | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'lib/puppet/file_serving/configuration/parser.rb') diff --git a/lib/puppet/file_serving/configuration/parser.rb b/lib/puppet/file_serving/configuration/parser.rb index f36bef639..c86e00a62 100644 --- a/lib/puppet/file_serving/configuration/parser.rb +++ b/lib/puppet/file_serving/configuration/parser.rb @@ -20,20 +20,20 @@ class Puppet::FileServing::Configuration::Parser < Puppet::Util::LoadedFile @count += 1 case line - when /^\s*#/: next # skip comments - when /^\s*$/: next # skip blank lines - when /\[([-\w]+)\]/: + when /^\s*#/; next # skip comments + when /^\s*$/; next # skip blank lines + when /\[([-\w]+)\]/ mount = newmount($1) - when /^\s*(\w+)\s+(.+)$/: + when /^\s*(\w+)\s+(.+)$/ var = $1 value = $2 raise(ArgumentError, "Fileserver configuration file does not use '=' as a separator") if value =~ /^=/ case var - when "path": + when "path" path(mount, value) - when "allow": + when "allow" allow(mount, value) - when "deny": + when "deny" deny(mount, value) else raise ArgumentError.new("Invalid argument '%s'" % var, -- cgit