revproxy: avoid path duplication after url rewrite
revproxy: avoid path duplication after url rewrite

The logic here seems broken, since we might be calling
singleJoiningSlash with the same path in both of its arguments. This
results in some forms of URL rewriting having the final path duplicated.

This likely needs rethinking or redesigning. For now, apply a much
smaller fix for 2.3.7 since it's safer and since this repository doesn't
have tests involving both the URL rewrite middleware and the reverse
proxy.

Fixes #855.

mvdan/tyk,mvdan/tyk,lonelycode/tyk,lonelycode/tyk,mvdan/tyk,mvdan/tyk,mvdan/tyk,mvdan/tyk,mvdan/tyk,mvdan/tyk,lonelycode/tyk