Fix for #486
Merge pull request #487 from csherratt/master

Fix for #486