diff options
author | Nate Walck <nate.walck@gmail.com> | 2016-08-29 21:29:45 -0700 |
---|---|---|
committer | Phil Dibowitz <phil@ipom.com> | 2016-08-29 21:29:45 -0700 |
commit | c16cf8be7c7f122a329171dfb13df51b8b60c0b2 (patch) | |
tree | 86931bde6afa9720beac83a0ba53fdcf2833187f /lib/chef/provider/osx_profile.rb | |
parent | 7fa458ad8fd0f428087449f79cc26b1d33cf50c6 (diff) | |
download | chef-c16cf8be7c7f122a329171dfb13df51b8b60c0b2.tar.gz |
Added fix for spaces in profile identifiers (#5159)
* Added fix for spaces in profile identifiers
* Added an attempt to test spaces in identifier names
* Derp, bad merge
* Fixed osx profile spec test
Diffstat (limited to 'lib/chef/provider/osx_profile.rb')
-rw-r--r-- | lib/chef/provider/osx_profile.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/chef/provider/osx_profile.rb b/lib/chef/provider/osx_profile.rb index f5535f5c37..69ecf2ddb9 100644 --- a/lib/chef/provider/osx_profile.rb +++ b/lib/chef/provider/osx_profile.rb @@ -69,14 +69,14 @@ class Chef a.assertion do !@new_profile_identifier.nil? && !@new_profile_identifier.end_with?(".mobileconfig") && - /^\w+(?:\.\w+)+$/.match(@new_profile_identifier) + /^\w+(?:(\.| )\w+)+$/.match(@new_profile_identifier) end a.failure_message RuntimeError, "when removing using the identifier attribute, it must match the profile identifier" else new_profile_name = @new_resource.profile_name a.assertion do !new_profile_name.end_with?(".mobileconfig") && - /^\w+(?:\.\w+)+$/.match(new_profile_name) + /^\w+(?:(\.| )\w+)+$/.match(new_profile_name) end a.failure_message RuntimeError, "When removing by resource name, it must match the profile identifier " end |