From 073c04cde8f9575d3027bbfd0b66480a123f63ff Mon Sep 17 00:00:00 2001 From: Scott Davis Date: Sat, 10 Dec 2011 12:55:54 -0500 Subject: [PATCH] 1.8.7 fix --- lib/compass/sass_extensions/sprites/layout_methods.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/compass/sass_extensions/sprites/layout_methods.rb b/lib/compass/sass_extensions/sprites/layout_methods.rb index dea34db0..b2728056 100644 --- a/lib/compass/sass_extensions/sprites/layout_methods.rb +++ b/lib/compass/sass_extensions/sprites/layout_methods.rb @@ -75,6 +75,7 @@ module Compass end def calculate_repeat_extra_width! + require 'rational' #for ruby 1.8.7 m = @images.inject(1) {|m,img| img.repeat_x? ? m.lcm(img.width) : m} remainder = @width % m @width += (m - remainder) unless remainder.zero?