apply #683 fix to dev branch