Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #139 from gazay/shadowing

Removed warning about shadowing outer local variable - option
  • Loading branch information...
commit b56a4f43be7734cc509c3f63919f7500f14269aa 2 parents 0580ad0 + 601ed81
@sferik sferik authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 lib/thor/group.rb
View
6 lib/thor/group.rb
@@ -187,9 +187,9 @@ def get_options_from_invocations(group_options, base_options) #:nodoc:
human_name = value.respond_to?(:classify) ? value.classify : value
group_options[human_name] ||= []
- group_options[human_name] += klass.class_options.values.select do |option|
- base_options[option.name.to_sym].nil? && option.group.nil? &&
- !group_options.values.flatten.any? { |i| i.name == option.name }
+ group_options[human_name] += klass.class_options.values.select do |class_option|
+ base_options[class_option.name.to_sym].nil? && class_option.group.nil? &&
+ !group_options.values.flatten.any? { |i| i.name == class_option.name }
end
yield klass if block_given?
Please sign in to comment.
Something went wrong with that request. Please try again.