Defect #7773 ยป 0001-Enable-none-admin-users-to-get-users-list-from-REST-.patch
app/controllers/users_controller.rb | ||
---|---|---|
18 | 18 |
class UsersController < ApplicationController |
19 | 19 |
layout 'admin' |
20 | 20 | |
21 |
before_action :require_admin, :except => :show |
|
21 |
before_action :require_admin, :except => [:show, :index] |
|
22 |
before_action :require_admin_or_api_request, :only => :index |
|
22 | 23 |
before_action :find_user, :only => [:show, :edit, :update, :destroy] |
23 | 24 |
accept_api_auth :index, :show, :create, :update, :destroy |
24 | 25 |