diff options
author | Adam Carpenter <atc@53hor.net> | 2020-04-23 18:01:31 -0400 |
---|---|---|
committer | Adam Carpenter <atc@53hor.net> | 2020-04-23 18:01:31 -0400 |
commit | ac6ea8dc4da8be20f69088ee71f32b05339c910c (patch) | |
tree | 0d34ff097a3cf076b64604a33d29f36de092b89a /src/js | |
parent | 2291e6fb5ad6e51669ad1147f18aa10ea603488a (diff) | |
download | carpentertutoring-ac6ea8dc4da8be20f69088ee71f32b05339c910c.tar.xz carpentertutoring-ac6ea8dc4da8be20f69088ee71f32b05339c910c.zip |
added temporary flip cards, ran through htmlhint and prettier
Diffstat (limited to 'src/js')
-rw-r--r-- | src/js/index.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/js/index.js b/src/js/index.js index 0697b51..77cdf65 100644 --- a/src/js/index.js +++ b/src/js/index.js @@ -29,7 +29,7 @@ const disableSuccessBox = function() { } const enableErrorBox = function(message) { - let errorBox = document.getElementById("errorBox"); + const errorBox = document.getElementById("errorBox"); let aTag = document.createElement('a'); aTag.setAttribute("href", "mailto:amy@carpentertutoring.com"); aTag.innerText = message + " Click here to send through your mail client."; @@ -48,10 +48,10 @@ const enableSuccessBox = function() { document.forms.inquiry.onsubmit = function() { disableErrorBox(); disableSuccessBox(); - let form = document.forms.inquiry; - let name = form.elements.name.value; - let fromEmail = form.elements.from.value; - let body = form.elements.body.value; + const form = document.forms.inquiry; + const name = form.elements.name.value; + const fromEmail = form.elements.from.value; + const body = form.elements.body.value; Email.send({ SecureToken : "cec9bc04-de48-48fd-b1ad-a95cffb41468", @@ -59,7 +59,7 @@ document.forms.inquiry.onsubmit = function() { From : fromEmail, Subject : "Inquiry: " + name, Body : body, - }).then( message => { + }).then(message => { if (message == "OK") { form.reset(); enableSuccessBox(); |