Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Factory
rubygem-sass
non-numeric.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File non-numeric.patch of Package rubygem-sass
diff --git a/lib/sass/script/value/number.rb b/lib/sass/script/value/number.rb index 9c21393..a066c5d 100644 --- a/lib/sass/script/value/number.rb +++ b/lib/sass/script/value/number.rb @@ -406,7 +406,13 @@ module Sass::Script::Value # Checks whether two numbers are within an epsilon of each other. # @return [Boolean] def self.basically_equal?(num1, num2) - (num1 - num2).abs < epsilon + if num1.is_a?(Numeric) && num2.is_a?(Numeric) + return (num1 - num2).abs < epsilon + end + if num1.is_a?(Numeric) || num2.is_a?(Numeric) + return false + end + return num1 == num2 end # @private
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor