Deprecated syntax for implementing auth lambda fails in Ruby 3.x
denny opened this issue · 1 comments
denny commented
The to_prepare
in engine.rb
method uses an implicit block to set the auth lambda, which isn't allowed in Ruby 3.x (and is flagged by rubocop in 2.7.2, I think).
To Reproduce
Set config.dashboard_auth_lambda
in a Ruby 3.x application and try to run it; it exits with the following error:
/home/denny/code/sail/lib/sail/engine.rb:54:in `new': tried to create Proc object without a block (ArgumentError)
from /home/denny/code/sail/lib/sail/engine.rb:54:in `to_prepare'
from /home/denny/code/sail/lib/sail/engine.rb:33:in `block in <class:Engine>'
[...]