Skip to content

Commit e05b4b5

Browse files
committed
Support old find_real_file arguments
1 parent 48af628 commit e05b4b5

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

lib/sass/rails/importer.rb

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,13 @@ def find(name, options)
9494

9595
private
9696
def find_filename(dir, name, options)
97-
full_filename, syntax = Sass::Util.destructure(find_real_file(dir, name, options))
98-
if full_filename && File.readable?(full_filename)
99-
return full_filename, syntax
97+
# Feature check additional options parameter that was added in 3.2.
98+
result = method(:find_real_file).arity == 2 ?
99+
find_real_file(dir, name) :
100+
find_real_file(dir, name, options)
101+
102+
if result && File.readable?(result[0])
103+
return result
100104
end
101105
end
102106

0 commit comments

Comments
 (0)