Promise not working in JS worker
Hi I have am using the S3 client in a Cloudflare worker
If I use
await
syntax I can log the results from this call in a Worker
If I try the same thing using .then()
syntax I do not get any logs
Can anyone please explain why?5 Replies
Why are you using a s3 client package, instead of the Wrangler bindings?
If the worker returns a response, it ends, and all dangling/left promises are cancelled
but yea, why not r2 binding?
Thanks heaps for that! that makes sense
I would like to transition to R2 binding but the documentation on how to get signed urls from the R2 bindings was not as clear as the S3 client doco
Thanks! managed to get it working using the R2 bindings, i had a small bug when i was trying to do this earlier