Just some (commented) refactoring.