diff options
author | Mark Rushakoff <mark.rushakoff@gmail.com> | 2012-04-29 10:33:35 -0700 |
---|---|---|
committer | Mark Rushakoff <mark.rushakoff@gmail.com> | 2012-04-29 11:03:11 -0700 |
commit | d56f5c8db7e937cabd07ff192c386f2aefed33a4 (patch) | |
tree | 60ef8436e6f8e6451fe48d01bb3ceb2ec33347cb /activerecord | |
parent | 54683f3a34edb6d2120291cbdb84b6197cb2eb35 (diff) | |
download | rails-d56f5c8db7e937cabd07ff192c386f2aefed33a4.tar.gz rails-d56f5c8db7e937cabd07ff192c386f2aefed33a4.tar.bz2 rails-d56f5c8db7e937cabd07ff192c386f2aefed33a4.zip |
Remove unused assignments
Diffstat (limited to 'activerecord')
-rw-r--r-- | activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb b/activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb index a609867898..46c7fc71ac 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb @@ -286,12 +286,10 @@ module ActiveRecord private def release(conn) - thread_id = nil - - if @reserved_connections[current_connection_id] == conn - thread_id = current_connection_id + thread_id = if @reserved_connections[current_connection_id] == conn + current_connection_id else - thread_id = @reserved_connections.keys.find { |k| + @reserved_connections.keys.find { |k| @reserved_connections[k] == conn } end |