This fixes #7770.