Open pboling opened 12 years ago
it is fixed in HEAD code
Thanks!
Please reopen this ticket.
On Ruby 1.9.3-p194, ruby_best_practices version 1.9.1, I am still getting the same error on the same line (line 9 above).
You may have solved for lambdas, but what I have here are lambdas within lambdas:
Snippet from previous comment to highlight the failure:
RANGES = lambda {
date_from_time = lambda do |src_time|
Time.mktime(src_time.year, src_time.month, src_time.day)
end
last_month = {
'range' => lambda { [date_from_time.(31.days.ago), date_from_time.(Time.now)] },
'value' => 'last_month',
'label' => 'Last month'}
}[]
It is dying on this line, which is a lambda nested within the outer lambda:
range' => lambda { [date_from_time.(31.days.ago), date_from_time.(Time.now)] },
Using latest code from master@9d6518fcca (add brace_block support in routes) I get an error processing a module (mixing) I have for adding date range capabilities to other code.
The Error
The Code