Made user object generation and jsonifying beautiful