There is a priority problem between the promise/await and array access. Fix this by prioritizing the promise result over then array access. It was causing the following error :
/home/XXXXX/project/src/applications/business/XXXX.ts:5
import {useStorage} from "../../storage";
^
Error: An error occurred while trying to generate a signed URL
at /home/XXXXX/project/src/applications/business/XXXX.ts:114:15
at Generator.next (<anonymous>)
at fulfilled (/home/XXXXX/project/src/applications/business/XXXX.ts:5:58)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
Summary:
There is a priority problem between the promise/await and array access. Fix this by prioritizing the promise result over then array access. It was causing the following error :
The code to reproduce
Tested on
Node 20.12.2 NPM 10.5.0