Fix compatibility with Rails 4.1.0

Fix based on @ktham's [fix for haml_coffee_assets](https://github.com/netzpirat/haml_coffee_assets/commit/7167b263e9bf852b2c63906752cb521f2ec89fc7)
More info at (rails/rails@3fbff78)