diff options
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters/abstract_adapter.rb')
-rwxr-xr-x | activerecord/lib/active_record/connection_adapters/abstract_adapter.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb index b01ef89dfc..8187112b64 100755 --- a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb @@ -63,11 +63,17 @@ module ActiveRecord # Is this connection active and ready to perform queries? def active? - true + @active != false end # Close this connection and open a new one in its place. def reconnect! + @active = true + end + + # Close this connection + def disconnect! + @active = false end |