File tree Expand file tree Collapse file tree 1 file changed +7
-5
lines changed
Expand file tree Collapse file tree 1 file changed +7
-5
lines changed Original file line number Diff line number Diff line change @@ -27,17 +27,19 @@ class Engine < ::Rails::Engine
2727 config . after_initialize do |app |
2828 require 'opal/rails/haml_filter' if defined? ( Haml )
2929
30+ config = app . config
3031 config . opal . each_pair do |key , value |
3132 key = "#{ key } ="
3233 Opal ::Processor . send ( key , value ) if Opal ::Processor . respond_to? key
3334 end
3435
35- config = app . config
36- maps_app = Opal ::SourceMapServer . new ( app . assets )
36+ if config . opal . source_map_enabled
37+ maps_app = Opal ::SourceMapServer . new ( app . assets )
3738
38- app . routes . prepend do
39- mount maps_app => maps_app . prefix
40- get '/opal_spec' => 'opal_spec#run'
39+ app . routes . prepend do
40+ mount maps_app => maps_app . prefix
41+ get '/opal_spec' => 'opal_spec#run'
42+ end
4143 end
4244 end
4345
You can’t perform that action at this time.
0 commit comments