Closes #946