sstephenson/ruby-yui-compressor — Issue #23: Not working on 1.9.2
Author: brian-pantano
Created: 2012-01-14 00:11:52+00:00
State: open

ruby -v
ruby 1.9.2p290 (2011-07-09 revision 32553) [x86_64-linux]

>> compressor = YUI::JavaScriptCompressor.new(:munge => true)
=> #"utf-8", :line_break=>nil, :munge=>true, :optimize=>true, :preserve_semicolons=>false}, @command="java -jar /usr/local/rvm/gems/ruby-1.9.2-p290/gems/yui-compressor-0.9.6/lib/yui/../yuicompressor-2.4.4.jar --type js --charset utf-8">
>> compressor.compress('(function () { var foo = {}; foo["bar"] = "baz"; })()')
NoMethodError: undefined method `map' for #
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/yui-compressor-0.9.6/lib/yui/compressor.rb:29:in `command'
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/yui-compressor-0.9.6/lib/yui/compressor.rb:68:in `block in compress'
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/yui-compressor-0.9.6/lib/yui/compressor.rb:117:in `streamify'
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/yui-compressor-0.9.6/lib/yui/compressor.rb:66:in `compress'
from (irb):8
from /usr/local/rvm/rubies/ruby-1.9.2-p290/bin/irb:16:in `

'