From 87d92b255313b3eff5231a57f8826c3812dfed41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Salvador=20P=C3=A9rez=20Garc=C3=ADa?= Date: Tue, 31 Jul 2018 12:59:02 +0200 Subject: [PATCH] Fixed issue with sprockets in production --- app/helpers/application_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index b9017beb2..b08e32a7f 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -62,7 +62,7 @@ module ApplicationHelper end def self.asset_data_base64(path) - asset = Rails.application.assets.find_asset(path) + asset = Rails.application.assets_manifest.find(path).first throw "Could not find asset '#{path}'" if asset.nil? base64 = Base64.encode64(asset.to_s).gsub(/\s+/, "") "data:#{asset.content_type};base64,#{Rack::Utils.escape(base64)}"