Fixes #776