Sha256: 4e37a92df47174c8e9c74323ed8c36f48f78525f6c8c7665c6caafe176393a2f
Contents?: true
Size: 446 Bytes
Versions: 3
Compression:
Stored size: 446 Bytes
Contents
module Apartment module Adapters class AbstractJDBCAdapter < AbstractAdapter protected # Return a new config that is multi-tenanted # def multi_tenantify(database) @config.clone.tap do |config| config[:url] = "#{config[:url].gsub(/(\S+)\/.+$/, '\1')}/#{environmentify(database)}" end end private def rescue_from ActiveRecord::JDBCError end end end end
Version data entries
3 entries across 3 versions & 1 rubygems