mongoid / mongoid-grid_fs

A pure Mongoid/Moped implementation of the MongoDB GridFS specification.
Other
83 stars 51 forks source link

Fix README for streaming write, #data => #each . #54

Closed tiredpixel closed 9 years ago

tiredpixel commented 9 years ago

The example given in README for 'streaming write' appears to be incorrect, with block not actually resulting in the data streaming. Instead, #each appears to yield the correct behaviour; this is what #data itself uses.

https://github.com/ahoward/mongoid-grid_fs/blob/master/lib/mongoid/grid_fs.rb#L323 https://github.com/ahoward/mongoid-grid_fs/blob/master/lib/mongoid/grid_fs.rb#L364

Peace, tiredpixel

rmm5t commented 9 years ago

Thanks!