Images = new Mongo.Collection("images");

// Set up security on images collection.
Images.allow({
  insert: function (userId, doc) {
    if (userId && userId === doc.createdBy) {
      console.log("Image insert allowed for " + userId, doc);
      return true;
    }
    else {
      return false;
    }
  },
  remove: function (userId, doc) {
    return true;
  }
});
