fix #821