refactored a bunch of things