Class: Shoppe::SettingsLoader

Inherits:
Object
  • Object
show all
Defined in:
lib/shoppe/settings_loader.rb

Instance Method Summary collapse

Constructor Details

#initialize(app) ⇒ SettingsLoader

Returns a new instance of SettingsLoader.


4
5
6
# File 'lib/shoppe/settings_loader.rb', line 4

def initialize(app)
  @app = app
end

Instance Method Details

#call(env) ⇒ Object


8
9
10
11
12
13
# File 'lib/shoppe/settings_loader.rb', line 8

def call(env)
  Shoppe.reset_settings
  @app.call(env)
ensure
  Shoppe.reset_settings
end