Fixes #5105 [skip ci]