forked from AkkomaGang/akkoma-fe
PersistedState: Replace object-path with lodash function
We were loading that one anyway.
This commit is contained in:
parent
8d7d4980b9
commit
178ff1672d
2 changed files with 2 additions and 4 deletions
|
@ -23,7 +23,6 @@
|
|||
"diff": "^3.0.1",
|
||||
"escape-html": "^1.0.3",
|
||||
"localforage": "^1.5.0",
|
||||
"object-path": "^0.11.3",
|
||||
"phoenix": "^1.3.0",
|
||||
"portal-vue": "^2.1.4",
|
||||
"v-click-outside": "^2.1.1",
|
||||
|
|
|
@ -1,13 +1,12 @@
|
|||
import merge from 'lodash.merge'
|
||||
import objectPath from 'object-path'
|
||||
import localforage from 'localforage'
|
||||
import { each } from 'lodash'
|
||||
import { each, get, set } from 'lodash'
|
||||
|
||||
let loaded = false
|
||||
|
||||
const defaultReducer = (state, paths) => (
|
||||
paths.length === 0 ? state : paths.reduce((substate, path) => {
|
||||
objectPath.set(substate, path, objectPath.get(state, path))
|
||||
set(substate, path, get(state, path))
|
||||
return substate
|
||||
}, {})
|
||||
)
|
||||
|
|
Loading…
Reference in a new issue