Updated based on comments in PR