fixes #4776