Skip to content

Commit

Permalink
feat: Add KUBESPHERE_EDITION constants to globals config
Browse files Browse the repository at this point in the history
Signed-off-by: yazhou <[email protected]>
  • Loading branch information
yazhouio committed Sep 24, 2024
1 parent 5c78cd0 commit e886511
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/core/src/run.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@ import i18n from './utils/i18n';
import emitter from './utils/emitter';

import App from './App';
import { isEmpty } from 'lodash';
import { isEmpty, set } from 'lodash';

globals.context = new Context();
set(globals, 'config.isKsEdition', process.env.KUBESPHERE_EDITION === 'ks');
set(globals, 'config.isKseEdition', process.env.KUBESPHERE_EDITION === 'kse');

globals.context = new Context();
if (!isEmpty(globals?.ksConfig?.enabledExtensionModulesStatus)) {
Object.entries(globals.ksConfig.enabledExtensionModulesStatus).forEach(([key, value]) => {
if ((value as Record<string, any>).annotations) {
Expand Down

0 comments on commit e886511

Please sign in to comment.