Fixes #1582: Error messages shown via client-side validation should not be double encoded