to fix #822