play-json icon indicating copy to clipboard operation
play-json copied to clipboard

Send non-breaking space (UTF8 00A0) through Json

Open scand1sk opened this issue 5 years ago • 2 comments

Play Version

2.8.2

API

Scala

Operating System

Linux vion-precision 5.7.0-1-amd64 playframework/playframework#1 SMP Debian 5.7.6-1 (2020-06-24) x86_64 GNU/Linux

JDK

openjdk version "1.8.0_252" OpenJDK Runtime Environment (build 1.8.0_252-8u252-b09-1-b09) OpenJDK 64-Bit Server VM (build 25.252-b09, mixed mode)

Expected Behavior

The action Ok(Json.obj("foo" -> "foo\u00a0bar")) should give the HTTP answer containing the given Json with a non-breaking space.

Actual Behavior

I do not know whether this is a bug or a feature, but the non-breaking space is converted to a standard space.

scand1sk avatar Jun 30 '20 12:06 scand1sk

Hi @scand1sk, is this a playframewwork issue or is it specific to play-json?

If the later, I can transfer ths issue to playframework/play-json.

ignasi35 avatar Jun 30 '20 14:06 ignasi35

Yep, it is probably specific to play-json.

scand1sk avatar Jul 01 '20 09:07 scand1sk