Meteor using a local connection results in error: insert failed: 404 — Method not found

后端 未结 2 1539
滥情空心
滥情空心 2020-12-16 04:00

I\'ve got a meteor collection on the client side

Friends = new Meteor.Collection(\"Friends\");
Meteor.subscribe(\"Friends\");

I have a user

2条回答
  •  暖寄归人
    2020-12-16 04:26

    You need that Collection declaration on both the client and the server.

    // common code, do not put under /client or inside Meteor.is_client test
    Friends = new Meteor.Collection("Friends");
    

提交回复
热议问题