How do i convert from type ?agent to agent... im so confused with optionals

Like this:

 Foo(MaybeAgent: ?agent): void =
        if (Agent := MaybeAgent?):
            # Do stuff with 'Agent'
4 Likes