[bugfix/wv-45] <back button fix on FindFriendsRoot> & [bugfix/wv-61] <updated code verification text> TEAM REVIEW #3824
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What github.com/wevote/WebApp/issues does this fix?
[bugfix/wv-45]
Changes included this pull request?
I seem to have got the back button working consistently. After adding a bunch of console.log statements to track the state of backButtonOn in FindFriendsRoot.jsx, I did find that it was acting inconsistently, where most of the time the state changed to true, but sometimes it didn’t.
I realized that the state variables all depended on the displayStep, setUpPagePath and nextStepVariables, so i started tracking those with console.log statements. I found that when the backButtonOn’s state stayed false, for some reason setUpPagePath console wouldn’t pop up.
Seeing that setNextStepVariables() set all of the state variables, I looked to see if this was being called in componentDidMount() like it was in componentDidUpdate(). It was not, so I placed setNextStepVariables() in the same part of the code that I saw it was placed in componentDidUpdate(). The back button seems to consistently show up now.