closes #542