No need for a @maybe_ref_param variable after all
case..when instead of multiple ifs in link_resolver