15954: Allow activating user using an admin token.
[arvados.git] / services / api / app / controllers / arvados / v1 / nodes_controller.rb
index 247d15e1c1ce76547aaa75975c95322d1e898887..eb72b7096de8776b7d930739417d9d50dab789f9 100644 (file)
@@ -3,9 +3,9 @@
 # SPDX-License-Identifier: AGPL-3.0
 
 class Arvados::V1::NodesController < ApplicationController
-  skip_before_filter :require_auth_scope, :only => :ping
-  skip_before_filter :find_object_by_uuid, :only => :ping
-  skip_before_filter :render_404_if_no_object, :only => :ping
+  skip_before_action :require_auth_scope, :only => :ping
+  skip_before_action :find_object_by_uuid, :only => :ping
+  skip_before_action :render_404_if_no_object, :only => :ping
 
   include DbCurrentTime
 
@@ -39,6 +39,7 @@ class Arvados::V1::NodesController < ApplicationController
     }
     @object.update_attributes!(attrs_to_update)
     @object.assign_slot if params[:assign_slot]
+    @object.save!
     show
   end