Allow 'confirm_email' and 'reset_password' views to return JSON when appropriate.