When I try to add new item in my Todolist App i get an error: dial tcp connect: connection refused

As i have mentioned, when I try to add a new item in my webiste I get a connection refused error. But when i reload my page i am able to see the items added and deleted when checked and meanwhile my MongoDB database is updated immediately.
Can someone help me with the issue of not reloading page and redirecting to other page automatically or should i have to refresh my UI component forcibly? if yes, how to achieve it?
My GitHub code for reference:GitHub - Varshaj666/TodoList_WebApp: User can create his todolist by adding items in today list and also he can create items in his customized list name by redirecting it.

Thanks in Advance


I would think your logs may have something to shed some more light on the issue.