mirror of
https://github.com/wahyd4/gitlabhq.git
synced 2026-08-18 17:16:08 +10:00
Fix using context of Projects::UpdateContext (in admin section error, in public section - to next step if moving controlers)
This commit is contained in:
committed by
Dmitriy Zaporozhets
parent
1dd0feacc7
commit
4ce715a360
@@ -29,7 +29,7 @@ class Admin::ProjectsController < Admin::ApplicationController
|
||||
end
|
||||
|
||||
def update
|
||||
status = Projects::UpdateContext.new(project, current_user, params).execute(:admin)
|
||||
status = ::Projects::UpdateContext.new(project, current_user, params).execute(:admin)
|
||||
|
||||
if status
|
||||
redirect_to [:admin, @project], notice: 'Project was successfully updated.'
|
||||
|
||||
@@ -19,7 +19,7 @@ class ProjectsController < ProjectResourceController
|
||||
end
|
||||
|
||||
def create
|
||||
@project = Projects::CreateContext.new(current_user, params[:project]).execute
|
||||
@project = ::Projects::CreateContext.new(current_user, params[:project]).execute
|
||||
|
||||
respond_to do |format|
|
||||
flash[:notice] = 'Project was successfully created.' if @project.saved?
|
||||
@@ -35,7 +35,7 @@ class ProjectsController < ProjectResourceController
|
||||
end
|
||||
|
||||
def update
|
||||
status = Projects::UpdateContext.new(project, current_user, params).execute
|
||||
status = ::Projects::UpdateContext.new(project, current_user, params).execute
|
||||
|
||||
respond_to do |format|
|
||||
if status
|
||||
|
||||
Reference in New Issue
Block a user