Many teams prefer to only run pipelines on merge requests instead of branches. This condition library only supports branch pipelines because of its use of CI_COMMIT_BRANCH

How about using CI_COMMIT_REF_NAME instead which is available on branch and merge request pipelines?