lib/scss_lint/engine.rb in scss_lint-0.43.1 vs lib/scss_lint/engine.rb in scss_lint-0.43.2
- old
+ new
@@ -45,10 +45,10 @@
# @option file [IO] if provided, us this as the file object
# @option path [String] path of file, loading from this if `file` object not
# given
def build_from_file(options)
@filename = options[:path]
- @contents = options[:file] ? file.read : File.read(@filename)
+ @contents = options[:file] ? options[:file].read : File.read(@filename)
@engine = Sass::Engine.new(@contents, ENGINE_OPTIONS.merge(filename: @filename))
end
# @param scss [String]
def build_from_string(scss)