mirror of
https://github.com/strapi/strapi.git
synced 2025-11-07 21:58:23 +00:00
Merge pull request #1581 from kamalbennani/bugfix/#1580/take-into-account-allowGa-config-prop
Take into account allowGa value
This commit is contained in:
commit
bc447d1167
@ -11,15 +11,15 @@ import { GET_GA_STATUS, GET_LAYOUT } from './constants';
|
|||||||
|
|
||||||
function* getGaStatus() {
|
function* getGaStatus() {
|
||||||
try {
|
try {
|
||||||
const [allowGa, strapiVersion, currentEnvironment] = yield [
|
const [{ allowGa }, { strapiVersion }, { currentEnvironment }] = yield [
|
||||||
call(request, '/admin/gaConfig', { method: 'GET' }),
|
call(request, '/admin/gaConfig', { method: 'GET' }),
|
||||||
call(request, '/admin/strapiVersion', { method: 'GET' }),
|
call(request, '/admin/strapiVersion', { method: 'GET' }),
|
||||||
call(request, '/admin/currentEnvironment', { method: 'GET' }),
|
call(request, '/admin/currentEnvironment', { method: 'GET' }),
|
||||||
];
|
];
|
||||||
|
|
||||||
yield put(getCurrEnvSucceeded(currentEnvironment.currentEnvironment));
|
yield put(getCurrEnvSucceeded(currentEnvironment));
|
||||||
yield put(getGaStatusSucceeded(allowGa));
|
yield put(getGaStatusSucceeded(allowGa));
|
||||||
yield put(getStrapiVersionSucceeded(strapiVersion.strapiVersion));
|
yield put(getStrapiVersionSucceeded(strapiVersion));
|
||||||
} catch(err) {
|
} catch(err) {
|
||||||
strapi.notification.error('notification.error');
|
strapi.notification.error('notification.error');
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user