Wouldn't it be better to use the built-in decodeUri() instead?