# Add data (connecting to backend) in react course

**URL:** <https://forum.codewithmosh.com/t/add-data-connecting-to-backend-in-react-course/21620>\
**Category:** Uncategorized\
**Created:** [July 21, 2023, 4:29pm UTC](https://forum.codewithmosh.com/t/add-data-connecting-to-backend-in-react-course/21620 "2023-07-21T16:29:10Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Razieh](https://avatars.discourse-cdn.com/v4/letter/r/439d5e/32.png) [@Razieh](https://forum.codewithmosh.com/u/Razieh)\
**Post date:** [July 21, 2023, 4:29pm UTC](https://forum.codewithmosh.com/t/add-data-connecting-to-backend-in-react-course/21620/1 "2023-07-21T16:29:10Z")

</div>

![Question](https://us1.discourse-cdn.com/flex020/uploads/codewithmosh/original/2X/c/c45288daac33c7876b7da67f32bfa1721c559bbe.jpeg)  
Dear All  
I hope all is well  
in the section of connecting to backend via a fake server address I face a problem  
1-we define the user  
2-we define a button and function to add data  
3-we write the function code  
i have problem in concept of part 3:  
in line 22 we define original users a users  
in line 24 we update users(which means the original users will be updated too, doesn’t it?)  
these lines related to updating the ul part, now in line 30 we say that if there is a problem on updating the server data, the users will be equal to original users,  
when we run the code and face problem on updating the serve and the original users come to be used, it return un -updated users, how does it come?
