You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by GitBox <gi...@apache.org> on 2022/11/18 17:03:47 UTC

[GitHub] [velocity-tools] diggernet commented on pull request #13: VELTOOLS-184

diggernet commented on PR #13:
URL: https://github.com/apache/velocity-tools/pull/13#issuecomment-1320290688

   That's a fair question.  I suppose the lazy answer is "because escapeJson() exists".  :)
   
   Comparing escapeJava() and escapeJson() shows they differ on two characters: / and \u007F.  I don't pretend to know why those differences exist, and in a quick test escapeJava() works without error.  But they do produce different output strings.  Without knowing the reason for this, I'd hesitate to assume that the output of escapeJava() is compatible with all existing JSON consuming code.  So using escapeJson() seems the safer choice.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@velocity.apache.org
For additional commands, e-mail: dev-help@velocity.apache.org