major changes to backend