# File lib/couchrest/database.rb, line 325 def delete_attachment(doc, name, force=false) uri = url_for_attachment(doc, name) # this needs a rev begin CouchRest.delete(uri) rescue Exception => error if force # get over a 409 doc = get(doc['_id']) uri = url_for_attachment(doc, name) CouchRest.delete(uri) else error end end end