Fixes #155

finally adding a PR for my local patch