diff --git a/app/helpers/application_helper/button/miq_request_delete.rb b/app/helpers/application_helper/button/miq_request_delete.rb index 0045d8edd2b..54806c88ac6 100644 --- a/app/helpers/application_helper/button/miq_request_delete.rb +++ b/app/helpers/application_helper/button/miq_request_delete.rb @@ -4,7 +4,7 @@ class ApplicationHelper::Button::MiqRequestDelete < ApplicationHelper::Button::M def disabled? requester = current_user - return false if requester.role_allows?(:feature => "miq_request_superadmin") + return false if requester.miq_user_role.request_admin_user? @error_message = _("Users are only allowed to delete their own requests") if requester.name != @record.requester_name if %w(approved denied).include?(@record.approval_state) @error_message = _("%{approval_states} requests cannot be deleted") %