This fixes #8307.