diff --git a/app/controllers/metal_decorator.rb b/app/controllers/metal_decorator.rb index 18ec22e4c8..0c8f81501f 100644 --- a/app/controllers/metal_decorator.rb +++ b/app/controllers/metal_decorator.rb @@ -1,6 +1,6 @@ # For the API ActionController::Metal.class_eval do def spree_current_user - @spree_current_user ||= env['warden'].user + @spree_current_user ||= request.env['warden'].user end end