@@ -11,4 +11,3 @@ underscore
sacha:spin
ian:accounts-ui-bootstrap-3
accounts-password
-insecure
@@ -20,7 +20,6 @@ htmljs@1.0.4
http@1.1.0
ian:accounts-ui-bootstrap-3@1.2.79
id-map@1.0.3
-insecure@1.0.3
iron:controller@1.0.8
iron:core@1.0.8
iron:dynamic-template@1.0.8
@@ -9,3 +9,10 @@
// Not a "var", to make it global.
Posts = new Mongo.Collection('posts');
+
+Posts.allow({
+ insert: function (userId, doc) {
+ // Only allow insert to logged-in users
+ return !!userId;
+ }
+});