# File lib/brb/tunnel/shared.rb, line 110 def treat_callback_return(ret, key, nb_out) if b = get_callback(key, nb_out) EM.defer do # With arity, handle multiple block arguments or no arguments b.arity == 1 ? b.call(ret) : (b.arity == 0 ? b.call : b.call(*ret)) end # A callback has been found and called, return true return true end # No callback, do nothing return nil end