mirror of https://github.com/scrapy/scrapy.git
Create item-pipeline.rst
This commit is contained in:
parent
fad6b70d92
commit
ae679f6499
|
|
@ -156,7 +156,7 @@ method and how to clean up the resources properly.::
|
|||
self.client.close()
|
||||
|
||||
def process_item(self, item, spider):
|
||||
self.db[self.collection_name].insert(dict(item))
|
||||
self.db[self.collection_name].insert_one(dict(item))
|
||||
return item
|
||||
|
||||
.. _MongoDB: https://www.mongodb.org/
|
||||
|
|
|
|||
Loading…
Reference in New Issue