Closed MinhxNguyen7 closed 5 months ago
@MinhxNguyen7 #865 hasn't been merged in yet, nor has its successor #891
Can't reproduce the error, is there a video you could share of the behavior?
@KevinWu098 I can make a video, but try it jn incognito. I reproduced it on a different device as well, so it's not just me
@KevinWu098 I can make a video, but try it jn incognito. I reproduced it on a different device as well, so it's not just me
export function removeSampleClasses() {
AppStore.deleteCourses(sampleClassesSectionCodes, CURRENT_TERM);
sampleClassesSectionCodes = [];
}
@MinhxNguyen7 This is the offending bit of code; It triggers this.unsavedChanges = true;
You can reproduce for yourself by just slapping a console.log
on every function with this.unsavedChanges = true
and seeing which triggers on load.
deleteCourses(sectionCodes: string[], term: string) {
sectionCodes.forEach((sectionCode) => this.deleteCourse(sectionCode, term));
console.log('deleteCourses');
this.unsavedChanges = true;
this.emit('addedCoursesChange');
}
Since deleteCourses
is only used by the Tutorial... the quickest fix would just be to omit this.unsavedChanges = true;
, but I've got a hunch that it could potentially cause hassle in the future if not properly documented.
Thoughts?
So it was me lmao
I'll look at it when I get back to my computer
So it was me lmao
I'll look at it when I get back to my computer
Description
It seems that any key press is causing the unsaved warning to show up. This includes either typing in the search bar or into the schedule load modal.
Related
865 might have changed the way that save states work, and I do remember seeing some weird code in there. @stevem-zhou do you have any ideas?