Replying late. This is also one of the best ways to ensure that you are eating better food. In my experience, it is much easier to cook a dinner with good food than to buy one. If I have leftovers of good food, I can turn one decision to eat better into two the next day.
For me, the trick here was to forget about the words "success" and "failure" because they have too much semantics embedded. I had to re-word the problem like this: call f3, if first argument of f1 and f2 are called. All other roads lead to f4. Both f1 and f2 has to be called in the chain no matter what.
Also, this is the first time I've seen such a pattern. Is there a practical application of such pattern? I think it's ok to have a single level of closure to continue execution, but if it goes to that many levels like the sample problem, it'll be a nightmare to maintain for people who have not seen your code yet.
Documents.length
Documents.first().set({title: "Changing the Title Syncs the View"})
Documents.first().set({description: "Lorem Ipsum Dolor Sit Amet"})
... then click on "Annotated Documents", at the top left, go back to the console, and try:
Documents.first().notes.fetch()
Documents.first().notes.first().set({content: "Writing a Note."})
I'd like to second the architecture side of this question. I'd love to see more on why and where a particular technology fits into web apps. Recently there has been a lot of popularity with Node.js, Backbone.js, and even Knockout.js. How and Where do these fit? What design decisions were made to achieve this?