From 795800a85f7ee3701e1f616ce44092e6f538545a Mon Sep 17 00:00:00 2001 From: Chris Eppstein Date: Mon, 15 Nov 2010 03:47:57 -0800 Subject: [PATCH] Return false if no false value is provided. --- lib/compass/sass_extensions/functions/if.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/compass/sass_extensions/functions/if.rb b/lib/compass/sass_extensions/functions/if.rb index 98c1591d..9f599de4 100644 --- a/lib/compass/sass_extensions/functions/if.rb +++ b/lib/compass/sass_extensions/functions/if.rb @@ -1,9 +1,9 @@ module Compass::SassExtensions::Functions::If - def if(truth, if_true, if_false) + def if(truth, if_true, if_false = nil) if truth.to_bool if_true else - if_false + if_false || Sass::Script::Bool.new(false) end end end