feat(js/main.js): client-side redirect to https when http is used