There is no Optimistic UI with findAndModify?


#1

I finally put my first Meteor app on staging and I have this weird problem, some functions doesn’t have Optimistic UI, for example when I upvote something, the vote increases and then instantly goes back down and then after a sec or so goes back up!!!
but some of the functions work as excepted, and the only difference is the functions with problematic Optimistic UI use findAndModify instead of update and insert !!

there was a list of supported mongo commands in docs that I can’t find now, is this because minimongo doesn’t support findAndModify???


#2

Correct - findAndModify is usable only via the Collection.rawCollection() object - so putting it into a method is probably the best way to use it. You can still use optimistic UI with methode by providing a client stub,