Skip to content

Commit

Permalink
Prefer each instead of for on activesupport
Browse files Browse the repository at this point in the history
  • Loading branch information
guilleiguaran committed May 24, 2011
1 parent 647c55a commit f4d100b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion activesupport/lib/active_support/buffered_logger.rb
Expand Up @@ -77,7 +77,7 @@ def add(severity, message = nil, progname = nil, &block)
# def info
# def warn
# def debug
for severity in Severity.constants
Severity.constants.each do |severity|
class_eval <<-EOT, __FILE__, __LINE__ + 1
def #{severity.downcase}(message = nil, progname = nil, &block) # def debug(message = nil, progname = nil, &block)
add(#{severity}, message, progname, &block) # add(DEBUG, message, progname, &block)
Expand Down

0 comments on commit f4d100b

Please sign in to comment.