moved code to backend and fixed some class calls