refactored stuff, in-progress commit (non functional)