Skip to content

Commit

Permalink
alias has? as include? for better Hash compatability
Browse files Browse the repository at this point in the history
Signed-off-by: Pat Nakajima <patnakajima@gmail.com>
  • Loading branch information
sbfaulkner authored and nakajima committed Mar 6, 2009
1 parent df053a7 commit 7a13ddd
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/rack/flash.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ def now
def has?(key)
[cache, values].any? { |store| store.keys.include?(key.to_sym) }
end
alias_method :include?, :has?

# Mark existing entries to allow for sweeping.
def flag!
Expand Down

0 comments on commit 7a13ddd

Please sign in to comment.