Human-Connection / WebApp

Human Connection is your super tool for social good! Let's go!
https://human-connection.org
MIT License
59 stars 27 forks source link

Comment reply: Updated content only appears after page refresh #247

Open sushidave opened 6 years ago

sushidave commented 6 years ago

Describe the bug After editing a comment reply the updated content is not instantly shown but only after a page refresh.

To Reproduce Steps to reproduce the behavior:

  1. Edit the reply of a comment.
  2. Click on the 'Save Comment' button.
  3. Check the reply - the updated version does not appear.
  4. Refresh the page in the brower.
  5. The updated version appears.

Expected behavior After saving the comment the updated version appears.

appinteractive commented 6 years ago

Might be that we only listen to the comment create but not the comment update events.

Lulalaby commented 6 years ago

Still a bug

Gerald1614 commented 5 years ago

I looked at the code and the same issue appears when deleting a comment. in fact, in both cases, we do not commit our action and use mutation to change the state of the comment. so the vuex store is still in old state when the submit the change. the value only gets updated when at the reload because the store is populated from the API entirely.

Gerald1614 commented 5 years ago

Hi, I could solve the issue. i still need to address same issue when deleting comment. i will add comments on discord and submit the code for revision soon

roschaefer commented 5 years ago

@Gerald1614 that's amazing, you already joined our Discord Server? If not: https://discord.gg/6ub73U3

Gerald1614 commented 5 years ago

yes, I did. i just do not know in which topics those things are discussed. I just also solved the issue with the delete part. let me know how you want me to proceed.

roschaefer commented 5 years ago

@Gerald1614 great :+1: send us a work-in-progress pull request, so we can give you early feedback. Prefix the title with [WIP] and write into the description fix #247. This will link the PR with this issue. On Discord, you can write in chat-en or coding-en (for English).