RR: remove unecessary if and fix indentation