change operations to be more modular