make decodeURI and decodeURIComponent work with malformed uris

see:
https://github.com/EventedMind/iron-router/issues/1117