Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reset fullfillmentNeeded for new Roads #382

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

ttpcodes
Copy link
Member

@ttpcodes ttpcodes commented Feb 9, 2020

This PR resets fulfillmentNeeded every time we switch to a different Road in CourseRoad. This works around the issue of new Roads that are switched to having their fullfillmentNeeded being set to none and thus not having their Fulfillment get reset during updateFulfillment.

This PR closes #344 and closes #366.

@ttpcodes ttpcodes force-pushed the new-road-reqs branch 3 times, most recently from a28194c to cff08d3 Compare February 9, 2020 03:44
@@ -295,6 +295,8 @@ export default {
_this.$store.commit('setRetrieved', newRoad);
});
} else if (newRoad !== '') {
// Reset fulfillmentNeeded so that new Roads still call FireRoad to check fulfillment.
this.$store.commit('resetFulfillmentNeeded');
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is calling update fulfillment twice when you create a new road while logged in (once on creation, once on name change). This should go specifically after a new road is added instead (in addRoad on MainPage).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants