Fixes #583