From 97e7988ed1acd18d2066b99214c9e5a56e66ed72 Mon Sep 17 00:00:00 2001 From: Max G Date: Mon, 10 Feb 2020 20:03:14 +0000 Subject: [PATCH] re #2 Force HTTPS on production when loading home page * Updated text on home page --- client/src/pages/HomePage.vue | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/client/src/pages/HomePage.vue b/client/src/pages/HomePage.vue index cf3195e..0bf7d89 100644 --- a/client/src/pages/HomePage.vue +++ b/client/src/pages/HomePage.vue @@ -105,6 +105,7 @@

Using an online note application

+

Assuming you have never used an note application previously in your life.


@@ -291,6 +292,14 @@ export default { } }, beforeMount(){ + + + + //Force HTTPS on prod, always. Dev doesn't have certs + const isDev = process.env['NODE_ENV'] == 'development' + if (!isDev && location.protocol != 'https:'){ + window.location.replace('https://www.avidhabit.com') + } //Don't change hero banner on mobile if(!this.$store.getters.getIsUserOnMobile){