Patch #24051 » 0001-As-a-non-admin-user-using-API-I-want-to-be-able-to-f.patch
| app/controllers/users_controller.rb | ||
|---|---|---|
|
class UsersController < ApplicationController
|
||
|
layout 'admin'
|
||
|
before_action :require_admin, :except => :show
|
||
|
before_action :require_admin, :except => [:show, :index]
|
||
|
before_action :find_user, :only => [:show, :edit, :update, :destroy]
|
||
|
accept_api_auth :index, :show, :create, :update, :destroy
|
||