Class: ROM::CouchDB::Commands::Delete

Inherits:
ROM::Commands::Delete
  • Object
show all
Defined in:
lib/rom/couchdb/commands.rb

Overview

CouchDB delete command

Instance Method Summary collapse

Instance Method Details

#collectionObject



34
35
36
# File 'lib/rom/couchdb/commands.rb', line 34

def collection
  relation.dataset
end

#execute(object) ⇒ Object



38
39
40
41
# File 'lib/rom/couchdb/commands.rb', line 38

def execute(object)
  collection.delete(object)
  [object]
end