Complete the function of add_user