added a fix, fixes #516