added another attempt to save state in couchdb

I need to handle this better, but for now just stack the callbacks