Reworked to be modular