Fixed things according to comments in PR #355