Finalize fix for #458
Merge pull request #460 from koenpunt/patch-1

Finalize fix for #458