fix getting started bug

This commit is contained in:
Sacha Greif 2016-03-01 14:01:12 +09:00
parent 4245323abf
commit e913cd6abc

View file

@ -13,7 +13,9 @@ Posts.methods = {};
*/
Posts.methods.new = function (post) {
post = Telescope.callbacks.run("posts.new.sync", post, Meteor.user());
const currentUser = Meteor.users.findOne(post.userId);
post = Telescope.callbacks.run("posts.new.sync", post, currentUser);
post._id = Posts.insert(post);