Merge pull request #172

With some small stylistic changes