[bugfix]for category controller, before calling authorize, should call find_project
This commit is contained in:
parent
4c7956ffa8
commit
7fa90d3427
@ -1,8 +1,7 @@
|
|||||||
class GlossaryCategoriesController < ApplicationController
|
class GlossaryCategoriesController < ApplicationController
|
||||||
|
|
||||||
before_action :authorize
|
|
||||||
before_action :find_category_from_id, only: [:show, :edit, :update, :destroy]
|
before_action :find_category_from_id, only: [:show, :edit, :update, :destroy]
|
||||||
before_action :find_project_from_id
|
before_action :find_project_from_id, :authorize
|
||||||
|
|
||||||
def index
|
def index
|
||||||
@categories = GlossaryCategory.where(project_id: @project.id)
|
@categories = GlossaryCategory.where(project_id: @project.id)
|
||||||
|
Loading…
Reference in New Issue
Block a user