You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@abdera.apache.org by "James M Snell (JIRA)" <ji...@apache.org> on 2008/05/12 18:28:55 UTC
[jira] Commented: (ABDERA-150) EncodingUtil.sanitize() behavior has
changed
[ https://issues.apache.org/jira/browse/ABDERA-150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12596119#action_12596119 ]
James M Snell commented on ABDERA-150:
--------------------------------------
Sorry, I meant UrlEncoding, not EncodingUtil, e.g.
String t = UrlEncoding.encode("foo bar", CharUtils.Profile.PATH.filter());
System.out.println(t);
Ultimately, however, the current behavior, while not backwards compatible, does produce a much more reasonable output for the intended purpose and should not be changed back
> EncodingUtil.sanitize() behavior has changed
> --------------------------------------------
>
> Key: ABDERA-150
> URL: https://issues.apache.org/jira/browse/ABDERA-150
> Project: Abdera
> Issue Type: Bug
> Affects Versions: 0.4.0
> Reporter: Todd Wells
>
> In the 3.0 client, EncodingUtil.sanitize() would escape a space in a String correctly -- with "%20". Now it replaces it with an underbar ("_").
> Sanitizer.sanitize() does the same thing. So existing code that depended on this method is now broken.
> For example when using Abdera with Mule Galaxy, it has a default URL that includes a space for it's atom feeds "Default Workspace", so the Abdera sanitizer couldn't be used reliably since it would make this "Default_Workspace". And looking at the code, sanitize only allows to to specify a particular slug to replace all undesired characters with -- so blindly saying replace with "%20" means that all undesired characters would be replaced with that, rather than with the proper HTML encoding.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.