Bug fix; closes #43