mirror of https://github.com/scrapy/scrapy.git
move buffer pointing to start of file before computing checksum. refs #92
This commit is contained in:
parent
3286ce4f42
commit
2dbf2a38a2
|
|
@ -252,6 +252,7 @@ class ImagesPipeline(MediaPipeline):
|
|||
checksum = None
|
||||
for key, image, buf in self.get_images(response, request, info):
|
||||
if checksum is None:
|
||||
buf.seek(0)
|
||||
checksum = md5sum(buf)
|
||||
self.store.persist_image(key, image, buf, info)
|
||||
return checksum
|
||||
|
|
|
|||
Loading…
Reference in New Issue