Skip to content

Commit

Permalink
fix specs
Browse files Browse the repository at this point in the history
  • Loading branch information
liu-samuel committed Nov 8, 2024
1 parent e7f22e1 commit 0c02479
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/controllers/ops_controller/ops_rbac.rb
Original file line number Diff line number Diff line change
Expand Up @@ -717,6 +717,7 @@ def rbac_edit_save_or_add(what, rbac_suffix = what)

case key
when :user
return unless load_edit("rbac_#{what}_edit__#{id}", "replace_cell__explorer")
record = @edit[:user_id] ? User.find_by(:id => @edit[:user_id]) : User.new
validated = rbac_user_validate?
rbac_user_set_record_vars(record)
Expand All @@ -726,6 +727,7 @@ def rbac_edit_save_or_add(what, rbac_suffix = what)
rbac_group_set_record_description_role(record) # Set new Description, Role and Tenant for a new Group
rbac_group_set_record_vars(record) if validated
when :role then
return unless load_edit("rbac_#{what}_edit__#{id}", "replace_cell__explorer")
record = @edit[:role_id] ? MiqUserRole.find_by(:id => @edit[:role_id]) : MiqUserRole.new
validated = rbac_role_validate?
rbac_role_set_record_vars(record)
Expand Down

0 comments on commit 0c02479

Please sign in to comment.