fix javascript escaping in error message