I’m trying to deploy my webapp for the first time and I’m getting this error on Vercel:
TypeError: Cannot read property ‘split’ of undefined
at Object.3qS3 (/vercel/path0/.next/serverless/pages/[collection]/[templateId].js:2510:16)
I’m recieving the error regarding multiple objects. I believe this is what’s causing the issue:
const balanceAmount = parseFloat(
currentUserBalance.split(' ')[0].replace(/[,]/g, '')
);
I don’t understand what’s causing the issue.