I have a sample code that includes storing index.html page on s3 and then using the API gateway to place the data inputted through the site to the dynamodb.
The code is working perfectly through the local machine but when I am running the same code and scripts through the bitbucket pipeline, I get this error every time.
" + serverless deploy --stage dev --conceal
Deploying "sample-form-service" to stage "dev" (us-east-1)
✖ Stack sample-form-service-dev failed to deploy (56s)
✖ Cannot read properties of undefined (reading 'remove')
TypeError: Cannot read properties of undefined (reading 'remove')
at /opt/atlassian/pipelines/agent/build/node_modules/serverless-s3-sync/index.js:302:22
at <anonymous>
"
Please help me find what is causing this issue.