Bug fix for paths like ``/samples/root/Getting Started/index.html``. Without encoding, the ``location.pathname`` does not match.