Fix issue 11764

Turns out the best fix was even simpler.