Rename and simplify code.