Permalink
Browse files

Use more compatible gzip write api instead of "<<".

Fixes undefined method `<<' for Zlib::GzipWriter on JRuby
  • Loading branch information...
josh committed Aug 4, 2009
1 parent 6ae0a10 commit b0f49bd0d6a5e7d6841168fe5e7de509aa1beac1
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/rack/deflater.rb
View
@@ -60,7 +60,7 @@ def each(&block)
@writer = block
gzip =::Zlib::GzipWriter.new(self)
gzip.mtime = @mtime
- @body.each { |part| gzip << part }
+ @body.each { |part| gzip.write(part) }
@body.close if @body.respond_to?(:close)
gzip.close
@writer = nil

0 comments on commit b0f49bd

Please sign in to comment.