Sha256: 1f4fdb1f91de8ba03142ed5f277f249736c243cd641e7a826e521e7f2a56d57c
Contents?: true
Size: 402 Bytes
Versions: 16
Compression:
Stored size: 402 Bytes
Contents
module Locomotive::Wagon module PersistAssetsConcern def replace_with_content_assets!(text) return text if text.blank? text.to_s.gsub(/\/samples\/\S*\.[a-zA-Z0-9]+/) do |match| url = __content_assets_pusher__.persist(match) url || match end end def asset_io(local_path) __content_assets_pusher__.decorate(local_path).source end end end
Version data entries
16 entries across 16 versions & 1 rubygems