class Dry::Monads::Maybe::Some::None::Mixin::Result::Task
Public Instance Methods
Source
# File lib/dry/monads/maybe.rb, line 375 def to_maybe if promise.wait.fulfilled? Maybe::Some.new(promise.value) else Maybe::None.new(RightBiased::Left.trace_caller) end end
Converts to Maybe
. Blocks the current thread if required.
@return [Maybe]