ruby - Why does this stylesheet get included in Rails development and not production? -
ruby - Why does this stylesheet get included in Rails development and not production? -
in layout application.html.haml have
- if featureswitch.where(name: 'display_demo', status: 'on').count > 0 = stylesheet_link_tag 'on_off_switch'
when have record, stylesheet gets included expected.
however, in production, on heroku, stylesheet doesn't included.
even though
featureswitch.where(name: 'display_demo', status: 'on') => #<activerecord::relation [#<featureswitch id: 2, status: "on", name: "display_demo", description: "", conditions: "", created_at: "2014-10-04 17:17:18", updated_at: "2014-10-05 14:44:29">]> irb(main):002:0> featureswitch.where(name: 'display_demo', status: 'on').count => 1
i tried having conditional in app/assets/stylesheets/application.css.erb (added .erb extension) no format used accepted.
right forced include stylesheet, regardless of truth of featureswitch.where(name: 'display_demo', status: 'on')
i'd way address it.
ruby-on-rails ruby ruby-on-rails-4 heroku
Comments
Post a Comment