safari doesn't like JSON response-types for XHR :(. thanks @cr for fixing this (+ some nits)
Merge branch 'cr-master'