got error TypeError: Cannot destructure property 'data' of '(intermediate value)' as it is undefined.