Class: UltraSettings::RackApp
- Inherits:
-
Object
- Object
- UltraSettings::RackApp
- Defined in:
- lib/ultra_settings/rack_app.rb
Overview
Rack application for displaying the current settings in an HTML page. No setting values are displayed, but you should still add some sort of authentication if you want to use this in production.
Instance Method Summary collapse
- #call(env) ⇒ Object
-
#initialize(color_scheme: nil) ⇒ RackApp
constructor
A new instance of RackApp.
Constructor Details
#initialize(color_scheme: nil) ⇒ RackApp
Returns a new instance of RackApp.
8 9 10 11 |
# File 'lib/ultra_settings/rack_app.rb', line 8 def initialize(color_scheme: nil) @webview = nil @color_scheme = color_scheme end |
Instance Method Details
#call(env) ⇒ Object
13 14 15 |
# File 'lib/ultra_settings/rack_app.rb', line 13 def call(env) [200, {"content-type" => "text/html; charset=utf8"}, [webview.render_settings]] end |