Module: MetalDecorator

Defined in:
app/controllers/metal_decorator.rb

Overview

For the API

Instance Method Summary collapse

Instance Method Details

#spree_current_userObject



3
4
5
6
7
8
9
# File 'app/controllers/metal_decorator.rb', line 3

def spree_current_user
  @spree_current_user ||=  if defined? env
                             env['warden'].user
                           else
                             request.env['warden'].user
                           end
end