Flux Layout - code refactoring

Just a little tidying.