adding a piece of code that updates an entry in couchdb