Skip to content
Permalink
Browse files

rename variable

  • Loading branch information
Alex Gaynor
Alex Gaynor committed Apr 15, 2013
1 parent 74c3351 commit cc6dccab609f28035cab591f41fdcfffd4a6227d
Showing with 6 additions and 6 deletions.
  1. +6 −6 lib-topaz/hash.rb
@@ -137,14 +137,14 @@ def inspect
def select!(&block)
return enum_for(:select!) unless block
raise RuntimeError.new("can't modify frozen #{self.class}") if frozen?
delete_p = false
modified = false
each_pair do |key, value|
unless yield key, value
delete key
delete_p = true
modified = true
end
end
delete_p ? self : nil
modified ? self : nil
end

def keep_if(&block)
@@ -162,14 +162,14 @@ def select(&block)
def reject!(&block)
return enum_for(:reject!) unless block
raise RuntimeError.new("can't modify frozen #{self.class}") if frozen?
delete_p = false
modified = false
each_pair do |key, value|
if yield key, value
delete key
delete_p = true
modified = true
end
end
delete_p ? self : nil
modified ? self : nil
end

def delete_if(&block)

2 comments on commit cc6dcca

@kachick

This comment has been minimized.

Copy link
Member

@kachick kachick replied Apr 15, 2013

I'm sorry to trouble you. :(

@alex

This comment has been minimized.

Copy link
Member

@alex alex replied Apr 15, 2013

Don't worry about it!

Please sign in to comment.
You can’t perform that action at this time.