scinote-web/lib/active_storage/service/custom_disk_service.rb

13 lines
333 B
Ruby
Raw Normal View History

# frozen_string_literal: true
require 'active_storage/service/disk_service'
module ActiveStorage
class Service::CustomDiskService < Service::DiskService
def url_options
ActiveStorage::Current.url_options ||= { host: Rails.application.secrets.mail_server_url }
ActiveStorage::Current.url_options
end
end
end