Skip to content

Commit

Permalink
simplify type
Browse files Browse the repository at this point in the history
  • Loading branch information
mattkime committed Aug 21, 2023
1 parent f3208c0 commit d5ccd00
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 9 deletions.
4 changes: 4 additions & 0 deletions src/plugins/data_views/common/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -525,3 +525,7 @@ export interface HasDataService {
hasUserDataView: () => Promise<boolean>;
hasDataView: () => Promise<boolean>;
}

export interface ClientConfigType {
scriptedFieldsEnabled?: boolean;
}
5 changes: 1 addition & 4 deletions src/plugins/data_views/public/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,14 @@
import { CoreSetup, CoreStart, Plugin, PluginInitializerContext } from '@kbn/core/public';
import { i18n } from '@kbn/i18n';
import { getIndexPatternLoad } from './expressions';
import type { ClientConfigType } from '../common/types';
import {
DataViewsPublicPluginSetup,
DataViewsPublicPluginStart,
DataViewsPublicSetupDependencies,
DataViewsPublicStartDependencies,
} from './types';

interface ClientConfigType {
scriptedFieldsEnabled?: boolean;
}

import { DataViewsApiClient } from '.';
import { ContentMagementWrapper } from './content_management_wrapper';

Expand Down
6 changes: 1 addition & 5 deletions src/plugins/data_views/server/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import { getIndexPatternLoad } from './expressions';
import { registerIndexPatternsUsageCollector } from './register_index_pattern_usage_collection';
import { createScriptedFieldsDeprecationsConfig } from './deprecations';
import { DATA_VIEW_SAVED_OBJECT_TYPE, LATEST_VERSION } from '../common';
import type { ClientConfigType } from '../common/types';
import {
DataViewsServerPluginSetup,
DataViewsServerPluginStart,
Expand All @@ -23,11 +24,6 @@ import {
} from './types';
import { DataViewsStorage } from './content_management';

// duped, change
interface ClientConfigType {
scriptedFieldsEnabled?: boolean;
}

export class DataViewsServerPlugin
implements
Plugin<
Expand Down

0 comments on commit d5ccd00

Please sign in to comment.