fixes #29667 I didn't add an integration test, but I can take a stab at it if you point me in the right direction!