Changes from comments in pull request #532