netzpirat/haml_coffee_assets — pull request #107 by magnusvk (2013-07-29 16:44:25+00:00)
Title: Don't butcher all template errors in Rails 4

Rails < 4.0 expects three arguments to ::ActionView::Template::Error.new, but Rails >= 4.0 expects just two. This was causing *all* of my errors to be butchered and replaced by a "wrong number of arguments" error in the haml_coffee_assets code. This here checks for the number of arguments expected and should work with both old and new versions of Rails.