Sha256: ad9c2fcf490119be05fc1724ac348c297ff478b3ad50e99fc85927334fa5b6d5
Contents?: true
Size: 556 Bytes
Versions: 11
Compression:
Stored size: 556 Bytes
Contents
# frozen_string_literal: true require 'fresh_connection/extend/adapters/base_adapter' module FreshConnection module Extend module M2Adapter private def __change_connection return yield unless FreshConnection::AccessControl.replica_access? master_connection = @connection begin replica_connection = @model_class.replica_connection @connection = replica_connection.raw_connection yield ensure @connection = master_connection end end end end end
Version data entries
11 entries across 11 versions & 1 rubygems