code general tidying