Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Find correct klass for rbac check for retirevms #1136

Merged
merged 2 commits into from Apr 25, 2017
Merged

Find correct klass for rbac check for retirevms #1136

merged 2 commits into from Apr 25, 2017

Commits on Apr 24, 2017

  1. Move code up and down, it could help, fingers crossed

    Just kidding, this will ensure we populate rec_cls variable first
    before the klass variable. That way we can re-use the rec_cls when
    populating klass variable.
    isimluk committed Apr 24, 2017
    Configuration menu
    Copy the full SHA
    0732b5e View commit details
    Browse the repository at this point in the history
  2. Find correct klass for rbac check for retirevms

    One would think that retirevms method would operate on Vm records.
    That's not the case. Caveat programmer!
    
    Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1442691
    
    Introduced in 457b085.
    
    Addressing:
    Error caught: [NoMethodError] undefined method `all' for nil:NilClass
    lib/rbac/filterer.rb:545:in `apply_scope'
    lib/rbac/filterer.rb:205:in `search'
    lib/rbac/filterer.rb:112:in `search'
    lib/rbac.rb:3:in `search'
    manageiq-ui-classic-d32ec1b1bfc2/app/controllers/application_controller.rb:2265:in `assert_rbac'
    manageiq-ui-classic-d32ec1b1bfc2/app/controllers/mixins/checked_id_mixin.rb:35:in `find_checked_ids_with_rbac'
    manageiq-ui-classic-d32ec1b1bfc2/app/controllers/application_controller/ci_processing.rb:219:in `retirevms'
    isimluk committed Apr 24, 2017
    Configuration menu
    Copy the full SHA
    414a9fb View commit details
    Browse the repository at this point in the history