Merge branch '2659-anonymous-share-projects' refs #2659
[arvados.git] / apps / workbench / app / controllers / jobs_controller.rb
index 9090d6404aac4b49f32f1414933cf598a46a37c5..b90210f6a9b7be4c7bbea8a1193000ac9e8a7a56 100644 (file)
@@ -1,7 +1,8 @@
 class JobsController < ApplicationController
-  if Rails.configuration.anonymous_user_token
-    skip_around_filter :require_thread_api_token, only: :show
-  end
+  skip_around_filter :require_thread_api_token, if: proc { |ctrl|
+    Rails.configuration.anonymous_user_token and
+    'show' == ctrl.action_name
+  }
 
   include JobsHelper