Stream<VcsRef> (@NotNull Stream<VcsRef> vcsRefs) { Stream<VcsRef> branches = vcsRefs.filter(ref -> { VcsRefType type = ref.getType(); return type == GitRefManager.LOCAL_BRANCH || type == GitRefManager.REMOTE_BRANCH || type == GitRefManager.TAG; }); return collectCommonVcsRefs(branches).stream(); }