Adapt to HTTPS enforcement