Closes #891