tidying up the where section