Don't ignore request.secure() when constructing URLs

Backport of https://github.com/playframework/playframework/commit/47cd92bbf64ccd428727612a6dc8b9b82aa08f88 to 2.3.x