Skip to content

Commit

Permalink
Goal loading cleanup; Fix goal history reversal bug. (#925)
Browse files Browse the repository at this point in the history
Cleanup and refactor: 
* Move currentUser check to within userEditFetch. 
* Remove unused GoalSelectorScroll. 
* Remove useless goal update in CharacterInventoryActions. 
* Replace custom functions getIndexInHistory and findGoalByName with use of .find(). 
* Make consistent usage of async/await with goal actions. 
Bug-fix: Remove .reverse() on the goal history in the state, and only reverse what is given to the history display. Resolves issues #243, #698, #795.
  • Loading branch information
imnasnainaec authored Jan 21, 2021
1 parent 7f06e93 commit 7e6c4ad
Show file tree
Hide file tree
Showing 20 changed files with 233 additions and 1,552 deletions.
4 changes: 0 additions & 4 deletions src/components/App/DefaultState.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { defaultState as reviewEntriesState } from "../../goals/ReviewEntries/Re
import { defaultProject } from "../../types/project";
import { defaultState as loginState } from "../Login/LoginReducer";
import { defaultState as goalTimelineState } from "../GoalTimeline/DefaultState";
import { defaultState as goalSelectorState } from "../GoalTimeline/GoalSelectorScroll/GoalSelectorReducer";
import { defaultState as passwordResetState } from "../PasswordReset/reducer";
import { defaultState as exportProjectState } from "../ProjectExport/ExportProjectReducer";
import { defaultState as createProjectState } from "../ProjectScreen/CreateProject/CreateProjectReducer";
Expand Down Expand Up @@ -46,9 +45,6 @@ export const defaultState = {
},

//general cleanup tools
goalSelectorState: {
...goalSelectorState,
},
goalsState: {
...goalTimelineState,
},
Expand Down

This file was deleted.

This file was deleted.

Loading

0 comments on commit 7e6c4ad

Please sign in to comment.