Revert part of #11302 to fix #12015

:(