diff options
author | Luke Kanies <luke@madstop.com> | 2008-04-08 11:19:15 -0500 |
---|---|---|
committer | Luke Kanies <luke@madstop.com> | 2008-04-08 11:19:15 -0500 |
commit | 80f8b80eacfa80bfd7b7d4f348838592161ed97a (patch) | |
tree | 1e02e4d952166f982c789e44243733b47b3b84a6 /lib | |
parent | 87f801bc17af22659b37fece2a0c4efdcdcc1e57 (diff) | |
download | puppet-80f8b80eacfa80bfd7b7d4f348838592161ed97a.tar.gz puppet-80f8b80eacfa80bfd7b7d4f348838592161ed97a.tar.xz puppet-80f8b80eacfa80bfd7b7d4f348838592161ed97a.zip |
Adding validation to the user type to confirm that the
group list does not contain any commas. This seems to be
a common problem.
Diffstat (limited to 'lib')
-rwxr-xr-x | lib/puppet/type/user.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/puppet/type/user.rb b/lib/puppet/type/user.rb index 48e35f2c8..71507d172 100755 --- a/lib/puppet/type/user.rb +++ b/lib/puppet/type/user.rb @@ -220,6 +220,9 @@ module Puppet if value =~ /^\d+$/ raise ArgumentError, "Group names must be provided, not numbers" end + if value.include?(",") + raise ArgumentError, "Group names must be provided as an array, not a comma-separated list" + end end end |