Cloud functions onUpdate: Cannot read property 'forEach' of undefined
问题 Now I am trying to update the picture in my project. I could update the picture url in the cloud fire store. But also I want to delete the previous picture from the cloud storage using firebase cloud functions. What I want to achieve is, to delete the previous picture from the cloud storage when I upload the new picture. This is my data structure. I have "sample" field in "Product" collection. When the picture in "sample" field is updated, I want to delete the original picture in the cloud