fixing login and register to make identify actually identify server-side