cleaned up the backend to be more usable