lib/asset_hat/js.rb in asset_hat-0.2.1 vs lib/asset_hat/js.rb in asset_hat-0.3.0

- old
+ new

@@ -28,16 +28,16 @@ def self.minify(input_string, options={}) options.reverse_merge!(:engine => :jsmin) engine = options[:engine].to_sym unless ENGINES.include?(engine) - raise %Q{ + raise %{ Unknown JS minification engine '#{engine}'. Allowed: #{ENGINES.map{ |e| "'#{e}'" }.join(', ')} }.strip.gsub(/\s+/, ' ') and return end - AssetHat::JS::Engines.send(engine, input_string) + AssetHat::JS::Engines.send(engine, input_string).strip end # Swappable JavaScript minification engines. module Engines # Barebones JavaScript minification engine that: