Some code tidying

Change-Id: I23b19b81e397808363aa1325dec686ecdfc591a2