fix(settings): respect configWhitelist
This commit is contained in:
parent
eae6f7760f
commit
5da4e43e50
|
@ -1,5 +1,6 @@
|
||||||
export * from './actions';
|
export * from './actions';
|
||||||
export * from './actionTypes';
|
export * from './actionTypes';
|
||||||
|
export { default as CONFIG_WHITELIST } from './configWhitelist';
|
||||||
export * from './functions';
|
export * from './functions';
|
||||||
|
|
||||||
import './middleware';
|
import './middleware';
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
// @flow
|
// @flow
|
||||||
|
import { CONFIG_WHITELIST, parseURLParams } from '../config';
|
||||||
import { parseURLParams } from '../config';
|
|
||||||
import { toState } from '../redux';
|
import { toState } from '../redux';
|
||||||
|
|
||||||
import { DEFAULT_SERVER_URL } from './constants';
|
import { DEFAULT_SERVER_URL } from './constants';
|
||||||
|
@ -55,12 +54,14 @@ export function getPropertyValue(
|
||||||
|
|
||||||
// urlParams
|
// urlParams
|
||||||
if (sources.urlParams) {
|
if (sources.urlParams) {
|
||||||
const urlParams
|
if (CONFIG_WHITELIST.indexOf(propertyName) !== -1) {
|
||||||
= parseURLParams(state['features/base/connection'].locationURL);
|
const urlParams
|
||||||
const value = urlParams[`config.${propertyName}`];
|
= parseURLParams(state['features/base/connection'].locationURL);
|
||||||
|
const value = urlParams[`config.${propertyName}`];
|
||||||
|
|
||||||
if (typeof value !== 'undefined') {
|
if (typeof value !== 'undefined') {
|
||||||
return value;
|
return value;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue