improving how the data object is created so the user object is not affected