Fixes according to code review feedback.