diff options
Diffstat (limited to 'app/controllers/projects_controller.rb')
-rw-r--r-- | app/controllers/projects_controller.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 9d1c44db137..4d7e33d7b11 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -148,7 +148,7 @@ class ProjectsController < Projects::ApplicationController def archive return access_denied! unless can?(current_user, :archive_project, @project) - @project.archive! + ::Projects::UpdateService.new(@project, current_user, archived: true).execute respond_to do |format| format.html { redirect_to project_path(@project) } @@ -158,7 +158,7 @@ class ProjectsController < Projects::ApplicationController def unarchive return access_denied! unless can?(current_user, :archive_project, @project) - @project.unarchive! + ::Projects::UpdateService.new(@project, current_user, archived: false).execute respond_to do |format| format.html { redirect_to project_path(@project) } |