method
preventing_writes?
v7.0.0 -
Show latest stable
- Class:
ActiveRecord::ConnectionAdapters::AbstractAdapter
preventing_writes?()public
Determines whether writes are currently being prevented.
Returns true if the connection is a replica.
If the application is using legacy handling, returns true if connection_handler.prevent_writes is set.
If the application is using the new connection handling will return true based on current_preventing_writes.