summaryrefslogtreecommitdiff
path: root/lib/chef/provider
diff options
context:
space:
mode:
authorPhil Dibowitz <phil@ipom.com>2015-10-20 18:31:09 -0700
committerPhil Dibowitz <phil@ipom.com>2015-10-20 18:31:09 -0700
commit00b6873865ded8d1e560c3b77dee8da6c9eb1b09 (patch)
tree3dd030414cda55fa00ebd6832d9dd64d8560119c /lib/chef/provider
parenta16d253bec53b8209a092d990c58bcb3e10bd3bd (diff)
parent5b2326a93c1c926ee0c302f57e46edabf8638fc7 (diff)
downloadchef-00b6873865ded8d1e560c3b77dee8da6c9eb1b09.tar.gz
Merge pull request #3119 from cmluciano/cml/bug1586
Fix condition of removing a group before user error.
Diffstat (limited to 'lib/chef/provider')
-rw-r--r--lib/chef/provider/user.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/chef/provider/user.rb b/lib/chef/provider/user.rb
index 244b11db98..76aefbf1c8 100644
--- a/lib/chef/provider/user.rb
+++ b/lib/chef/provider/user.rb
@@ -89,7 +89,7 @@ class Chef
end
def define_resource_requirements
- requirements.assert(:all_actions) do |a|
+ requirements.assert(:create, :modify, :manage, :lock, :unlock) do |a|
a.assertion { @group_name_resolved }
a.failure_message Chef::Exceptions::User, "Couldn't lookup integer GID for group name #{@new_resource.gid}"
a.whyrun "group name #{@new_resource.gid} does not exist. This will cause group assignment to fail. Assuming this group will have been created previously."