Changed update and insert to use async.waterfall

Made the changes necessary to get ready to add some of the new features that we have been discussing. I basically introduced waterfall to `insert` and `update`. All tests pass.