Error: Reference.child failed: First argument was an invalid path

后端 未结 2 713
南笙
南笙 2021-01-24 23:45

I have this small app with Firebase and i\'m implementing CRUD operations. The issue comes when I have to delete a post. I get this error: Error: Reference.child failed: F

2条回答
  •  花落未央
    2021-01-25 00:39

    You seem to be changing the meaning of p from post to an id. Assuming that each post has an id property, you probably want:

    delete(post) {
      this.postService.deletePost(post.id)
    }
    

提交回复
热议问题