diff --git a/components/index/cards/workshops.js b/components/index/cards/workshops.js index 3e3584db..b986e401 100644 --- a/components/index/cards/workshops.js +++ b/components/index/cards/workshops.js @@ -16,7 +16,6 @@ const WorkshopCard = ({ }) => ( { `/api/channels/resolve/?id=${lastJsonMessage.channel}` ) .then(r => r.json()) - .catch(err => console.log(err)) + .catch(err => console.error(err)) if (whitelistedChannels.has(name)) { //this check should happen before the web req, to save on net resources diff --git a/lib/use-form.js b/lib/use-form.js index 2e08963a..530cd621 100644 --- a/lib/use-form.js +++ b/lib/use-form.js @@ -49,7 +49,6 @@ const useForm = ( }) .then(r => r.json()) .then(r => { - console.log('Form success!') setStatus('success') if (callback) callback(r) setTimeout(() => setStatus('default'), 3500) diff --git a/pages/amas/geohot.js b/pages/amas/geohot.js index 35e2e4f0..bfc103d3 100644 --- a/pages/amas/geohot.js +++ b/pages/amas/geohot.js @@ -12,7 +12,6 @@ export default function Geohot() { if (typeof window !== 'undefined') { setTimeout(function () { window.location.reload() - console.log('hi') }, milliseconds) } diff --git a/pages/amas/sal.js b/pages/amas/sal.js index 19b21e25..699a31c3 100644 --- a/pages/amas/sal.js +++ b/pages/amas/sal.js @@ -12,7 +12,6 @@ export default function Sal() { if (typeof window !== 'undefined') { setTimeout(function () { window.location.reload() - console.log('hi') }, milliseconds) } diff --git a/pages/api/bank/apply.js b/pages/api/bank/apply.js index 9e67d0f9..e51aded4 100644 --- a/pages/api/bank/apply.js +++ b/pages/api/bank/apply.js @@ -53,10 +53,9 @@ export default async function handler(req, res) { 'Slack Username': data.slackUsername }) res.writeHead(302, { Location: '/bank/apply/success' }).end() - console.log(r) }) .catch(error => { - console.log(error) + console.error(error) res.writeHead(500, { Location: `/bank/apply?step=3&airtable-error=${error}` }) diff --git a/pages/api/bank/demo.js b/pages/api/bank/demo.js index edf1cda2..3bbc3dfa 100644 --- a/pages/api/bank/demo.js +++ b/pages/api/bank/demo.js @@ -27,8 +27,6 @@ export default async function handler(req, res) { }) .then(r => r.json()) .then(async r => { - console.log(data) - await applicationsTable.create({ 'Email Address': data.userEmail, 'Event Name': `${data.eventName} (${data.teamType} ${data.teamNumber})`, @@ -40,7 +38,7 @@ export default async function handler(req, res) { .json({ message: 'Success! Check your email for next steps.' }) }) .catch(error => { - console.log(error) + console.error(error) res.json({ status: 'Something went wrong', error }) }) } else { diff --git a/pages/api/channels/resolve.js b/pages/api/channels/resolve.js index 37ef865a..c04e7758 100644 --- a/pages/api/channels/resolve.js +++ b/pages/api/channels/resolve.js @@ -10,13 +10,13 @@ export default async function handler(req, res) { ) if (!channelDataReq.ok) { - console.log(await channelDataReq.text()) + console.warn(await channelDataReq.text()) return res.status(503).end() } const channelData = await channelDataReq.json() if (!channelData.ok) { - console.log(channelData) + console.warn(channelData) return res.status(400).end() } diff --git a/pages/api/join.js b/pages/api/join.js index 7bd04a3d..94f37299 100644 --- a/pages/api/join.js +++ b/pages/api/join.js @@ -7,7 +7,6 @@ const joinTable = new AirtablePlus({ }) async function postData(url = '', data = {}, headers = {}) { - console.log(data) const response = await fetch(url, { method: 'POST', mode: 'cors', @@ -84,7 +83,6 @@ export default async function handler(req, res) { }, { authorization: `Bearer ${process.env.TORIEL_KEY}` } ) - console.log(result) res.json({ status: 'success', message: 'You’ve been invited to Slack!' }) } else { res.json({ diff --git a/pages/api/stickers.js b/pages/api/stickers.js index 7d39cefe..4d933a02 100644 --- a/pages/api/stickers.js +++ b/pages/api/stickers.js @@ -32,7 +32,7 @@ export default async function handler(req, res) { filterByFormula: `AND({Email} = '${data.email}', {Is Valid?} = '1', {Club} = '')` }) )[0] - console.log('address', address) + if (!address) { address = await addressesTable.create({ 'Street (First Line)': data.addressFirst, @@ -43,8 +43,6 @@ export default async function handler(req, res) { Country: data.country, Person: [personRecord.id] }) - - console.log('created address:', address) } if ( @@ -80,10 +78,9 @@ export default async function handler(req, res) { }) .then(r => { res.json({ status: 'success' }) - console.log(r.statusText) }) .catch(error => { - console.log(error) + console.error(error) res.json({ status: 'error', error }) }) } else { diff --git a/pages/api/winter-rsvp.js b/pages/api/winter-rsvp.js index 9d912442..e8a9a1a2 100644 --- a/pages/api/winter-rsvp.js +++ b/pages/api/winter-rsvp.js @@ -27,7 +27,7 @@ export default async function handler(req, res) { }) .then(res => res.status(200).json({ success: true })) .catch(error => { - console.log(error) + console.error(error) res.json({ status: 'Something went wrong', error }) }) } else { diff --git a/pages/bank/apply.js b/pages/bank/apply.js index 3ee2a683..52ca5ccc 100644 --- a/pages/bank/apply.js +++ b/pages/bank/apply.js @@ -21,7 +21,6 @@ const valiadateAddress = async step => { // Get the raw personal address input const userAddress = sessionStorage.getItem('bank-signup-userAddress') - console.log(userAddress) if (!userAddress) return const result = await geocode(userAddress) @@ -62,7 +61,7 @@ export default function Apply() { ] useEffect(() => { - console.log(`Form error: ${formError}`) + console.error(`Form error: ${formError}`) if (!router.isReady) return setStep(parseInt(router.query.step)) diff --git a/pages/index.js b/pages/index.js index 02e3bcc3..edf8edce 100644 --- a/pages/index.js +++ b/pages/index.js @@ -115,10 +115,11 @@ function Page({ ] // janky right now and does not show last image - console.log( - `White sheets of paper\nWaiting to be printed on\nA blank console waits` - ) + useEffect(() => { + console.log( + `White sheets of paper\nWaiting to be printed on\nA blank console waits` + ) if (count === images.length - 1) { setCount(0) } @@ -152,11 +153,9 @@ function Page({ reveal={reveal} onMouseEnter={() => { setHover(true) - console.log('hover:', hover) }} onMouseOut={() => { setHover(false) - console.log('hover:', hover) }} /> @@ -361,7 +360,6 @@ function Page({ }} onClick={() => { setCount(count + 1) - console.log(count) }} >