删除父级时未调用 Cloud Functions for Firebase onWrite 触发器 [英] Cloud Functions for Firebase onWrite trigger not called when parent is deleted

查看:18
本文介绍了删除父级时未调用 Cloud Functions for Firebase onWrite 触发器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Cloud Functions onWrite 监听这条路径:

I am listening to this path using Cloud Functions onWrite:

/msgr/{a}/users/{b}

现在假设 users 下有 100 个孩子.

Now assume that there are 100 children under users.

当我从控制台中删除 /msgr/x/users/12 时,会运行 onWrite 触发器,这与预期的一样.

When I delete /msgr/x/users/12 from the console, the onWrite trigger is run, which is as expected.

但是,如果我从控制台中删除 /msgr/x/users,则 onWrite 函数根本不会运行.我希望 onWrite 触发器运行 100 次,与 users 下的子项数量一样多.

However, if I delete /msgr/x/users from the console, the onWrite function is not run at all. I expect that the onWrite trigger is run 100 times, as much as the number of children under users.

这是预期的行为吗?

推荐答案

作为 Firebaser Tom 在 firebase-talk 邮件列表中说:

As fellow Firebaser Tom said on the firebase-talk mailing list:

感谢报告,我发现了两个错误,希望在 5 月 10 日之前将它们投入生产.

Thanks for reporting, I found two bugs, I hope to have them rolled out to production by May 10th.

更新:这个问题已经修复.将我原来的回复留给后人.

这篇关于删除父级时未调用 Cloud Functions for Firebase onWrite 触发器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆