haha it exists but isn’t exposed! that’s weird.
if you think it does the right thing and should become public, please do open an issue on github about it. it looks to be very useful. maybe someone else will supply the pull request, maybe they’ll convince you to DIY.