Close GH-40: Fixing a regression bug. Fixes #39