rails/rails — pull request #17679 by StevenNunez (2014-11-19 21:33:26+00:00)
Title: Cast values passed to escape_javascript to string

Calling escape_javascript on anything that's not a string fails since `gsub` is called. Casting as string fixes this.