refactoring + reorganising