|
@@ -12,7 +12,16 @@ Posts = new Mongo.Collection('posts');
|
|
|
|
|
|
|
|
|
|
|
|
-
|
|
|
+Posts.allow({
|
|
|
+ update: function (userId, post) {
|
|
|
+ return ownsDocument(userId, post);
|
|
|
+ },
|
|
|
+ remove: function (userId, post) {
|
|
|
+ return ownsDocument(userId, post);
|
|
|
+ }
|
|
|
+});
|
|
|
+
|
|
|
+
|
|
|
Meteor.methods({
|
|
|
postInsert: function(postAttributes) {
|
|
|
"use strict";
|