fixed #798