added databse relationships
added consistent error codes
removed messages from being sent with login data