From a87f4563bea9483a49aafa29a24aabce08edc89d Mon Sep 17 00:00:00 2001 From: Vojta Drbohlav Date: Tue, 16 Feb 2016 00:37:24 +0100 Subject: [PATCH] Fixed TypeError: no implicit conversion of Sprockets::Asset into String when using sprockets 3. --- lib/compass-rails/patches/compass.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/compass-rails/patches/compass.rb b/lib/compass-rails/patches/compass.rb index 3a24366..c70d864 100644 --- a/lib/compass-rails/patches/compass.rb +++ b/lib/compass-rails/patches/compass.rb @@ -4,7 +4,7 @@ def image_path_for_size(image_file) begin file = ::CompassRails.sprockets.find_asset(image_file) - return file + return (file.respond_to?(:pathname) ? file.pathname.to_s : file) rescue ::Sprockets::FileOutsidePaths return super(image_file) end