mirror of
https://github.com/muerwre/orchidmap-front.git
synced 2025-04-24 18:46:40 +07:00
fixed provider and logo persistence
This commit is contained in:
parent
b421005b7d
commit
a3982eddae
1 changed files with 7 additions and 1 deletions
|
@ -25,6 +25,12 @@ import { assocPath } from 'ramda';
|
||||||
import { AxiosError } from 'axios';
|
import { AxiosError } from 'axios';
|
||||||
import { api } from '~/utils/api/instance';
|
import { api } from '~/utils/api/instance';
|
||||||
|
|
||||||
|
const mapPersistConfig: PersistConfig = {
|
||||||
|
key: 'map',
|
||||||
|
whitelist: ['logo', 'provider'],
|
||||||
|
storage,
|
||||||
|
};
|
||||||
|
|
||||||
const userPersistConfig: PersistConfig = {
|
const userPersistConfig: PersistConfig = {
|
||||||
key: 'user',
|
key: 'user',
|
||||||
whitelist: ['user', 'logo', 'provider', 'speed'],
|
whitelist: ['user', 'logo', 'provider', 'speed'],
|
||||||
|
@ -55,7 +61,7 @@ export const store = createStore(
|
||||||
combineReducers({
|
combineReducers({
|
||||||
user: persistReducer(userPersistConfig, userReducer),
|
user: persistReducer(userPersistConfig, userReducer),
|
||||||
editor: persistReducer(editorPersistConfig, editor),
|
editor: persistReducer(editorPersistConfig, editor),
|
||||||
map,
|
map: persistReducer(mapPersistConfig, map),
|
||||||
}),
|
}),
|
||||||
composeEnhancers(applyMiddleware(sagaMiddleware))
|
composeEnhancers(applyMiddleware(sagaMiddleware))
|
||||||
);
|
);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue