added magic encoding
fix for bad stuff
fix for bad stuff
add encoding to js
Merge remote-tracking branch 'swistaczek/master'

Conflicts:
	spec/js_routes_spec.rb
	spec/spec_helper.rb
Prettify formatting