Fixes the issue in LP #1331744 comment #2
Updated fix
more fixing
Merge pull request #127 from davecheney/lp-1331744

Fixes the issue in LP #1331744 comment #2