in reply to Try::Tiny - return in catch from sub

Read the Try::Tiny documentation:

return returns from the try block, not from the parent sub (note that this is also how eval works, but not how TryCatch works):

I would return a value from the try block that signals error or no error, and put the subs return() outside of the try block

  • Comment on Re: Try::Tiny - return in catch from sub