Merge pull request #136 from hashar/rake-task-args
Fix args handling for rake strings::generate
This commit is contained in:
commit
9fc7fe2ff7
|
@ -14,8 +14,11 @@ namespace :strings do
|
||||||
markup: args[:markup] || 'markdown',
|
markup: args[:markup] || 'markdown',
|
||||||
}
|
}
|
||||||
|
|
||||||
options[:json] = args[:json] if args.key? :json
|
# rubocop:disable Style/PreferredHashMethods
|
||||||
options[:yard_args] = args[:yard_args].split if args.key? :yard_args
|
# `args` is a Rake::TaskArguments and has no key? method
|
||||||
|
options[:json] = args[:json] if args.has_key? :json
|
||||||
|
options[:yard_args] = args[:yard_args].split if args.has_key? :yard_args
|
||||||
|
# rubocop:enable Style/PreferredHashMethods
|
||||||
|
|
||||||
PuppetStrings.generate(patterns, options)
|
PuppetStrings.generate(patterns, options)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue