First pass at #332
Merge pull request #777 from ritchiewilson/patch-2

First pass at #332