resolves #807 on master