Skip to content
This repository
Browse code

Remove unused assignments

  • Loading branch information...
commit d56f5c8db7e937cabd07ff192c386f2aefed33a4 1 parent 54683f3
Mark Rushakoff authored April 29, 2012
1  actionpack/lib/action_dispatch/middleware/cookies.rb
@@ -339,7 +339,6 @@ def initialize(app)
339 339
     end
340 340
 
341 341
     def call(env)
342  
-      cookie_jar = nil
343 342
       status, headers, body = @app.call(env)
344 343
 
345 344
       if cookie_jar = env['action_dispatch.cookies']
8  activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb
@@ -286,12 +286,10 @@ def reap
286 286
       private
287 287
 
288 288
       def release(conn)
289  
-        thread_id = nil
290  
-
291  
-        if @reserved_connections[current_connection_id] == conn
292  
-          thread_id = current_connection_id
  289
+        thread_id = if @reserved_connections[current_connection_id] == conn
  290
+          current_connection_id
293 291
         else
294  
-          thread_id = @reserved_connections.keys.find { |k|
  292
+          @reserved_connections.keys.find { |k|
295 293
             @reserved_connections[k] == conn
296 294
           }
297 295
         end
2  activesupport/lib/active_support/testing/performance/jruby.rb
@@ -42,7 +42,7 @@ def record
42 42
           klasses.each do |klass|
43 43
             fname = output_filename(klass)
44 44
             FileUtils.mkdir_p(File.dirname(fname))
45  
-            file = File.open(fname, 'wb') do |file|
  45
+            File.open(fname, 'wb') do |file|
46 46
               klass.new(@data).printProfile(file)
47 47
             end
48 48
           end
1  railties/lib/rails/commands/runner.rb
@@ -9,7 +9,6 @@
9 9
 end
10 10
 
11 11
 ARGV.clone.options do |opts|
12  
-  script_name = File.basename($0)
13 12
   opts.banner = "Usage: runner [options] ('Some.ruby(code)' or a filename)"
14 13
 
15 14
   opts.separator ""

0 notes on commit d56f5c8

Please sign in to comment.
Something went wrong with that request. Please try again.