lib/miam/client.rb in miam-0.2.2.beta2 vs lib/miam/client.rb in miam-0.2.2.beta3
- old
+ new
@@ -131,12 +131,16 @@
updated = true
elsif not expected_login_profile and actual_login_profile
@driver.delete_login_profile(user_name)
updated = true
elsif expected_login_profile != actual_login_profile
- @driver.update_login_profile(user_name, expected_login_profile, actual_login_profile)
- updated = true
+ if @options[:ignore_login_profile]
+ log(:warn, "User `#{user_name}`: difference of loging profile has been ignored: expected=#{expected_login_profile.inspect}, actual=#{actual_login_profile.inspect}", :color => :yellow)
+ else
+ @driver.update_login_profile(user_name, expected_login_profile, actual_login_profile)
+ updated = true
+ end
end
updated
end
@@ -396,9 +400,11 @@
updated
end
def walk_policy(type, user_or_group_name, policy_name, expected_document, actual_document)
updated = false
+ expected_document.sort_array!
+ actual_document.sort_array!
if expected_document != actual_document
@driver.update_policy(type, user_or_group_name, policy_name, expected_document, actual_document)
updated = true
end