Meteor-Community-Packages / meteor-collection-hooks

Meteor Collection Hooks
https://atmospherejs.com/matb33/collection-hooks
MIT License
657 stars 92 forks source link

executing code before an autoform update #82

Closed ZHosseinpour closed 9 years ago

ZHosseinpour commented 9 years ago

I want to do something before an autoform update occur . i use ' coll.before.update ' to execute my logic in its function but the callback function dos not execute even though the update occur . i don't know where i made mistake or if anything else i should do. this is my code:

ads.before.update(function(userId, doc,fieldNames, modifier, options) {
 console.log("doc");
 doc.img = Session.get("imgAds");
 // doc.linkItem=Session.get("itmId")
 });
matb33 commented 9 years ago

Are you still having an issue or have you resolved it?

ZHosseinpour commented 9 years ago

My problem was solved,thanks.