Added logic for add user functionality