Update code based on review comments.