Bug fix #59

Working on #9