Skip to content

Commit

Permalink
Make InMemoryStorage class inherent BaseStorage
Browse files Browse the repository at this point in the history
Since in the previous commit a new base class for storage object is
added, the class of InMemoryStorage inherent this new BaseStorage to
enable it with the methods of BaseStorage.
  • Loading branch information
grammy-jiang committed Jul 17, 2018
1 parent 55a3ded commit 72be0ae
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions scrapy_cookies/storage/in_memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,10 @@

from scrapy.http.cookies import CookieJar

from scrapy_cookies.storage import BaseStorage

class InMemoryStorage(defaultdict):

class InMemoryStorage(defaultdict, BaseStorage):
def __init__(self, settings):
super(InMemoryStorage, self).__init__(CookieJar)
self.settings = settings

def open_spider(self, spider):
pass

def close_spider(self, spider):
pass

0 comments on commit 72be0ae

Please sign in to comment.