fixes #506 and #508