fixes #513