refactored user createuser method to return returndata struct and made changes in main