Skip to content

Commit

Permalink
remove fluff
Browse files Browse the repository at this point in the history
  • Loading branch information
tsullivan committed Feb 24, 2021
1 parent f886eed commit d0ac0bb
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 11 deletions.
7 changes: 0 additions & 7 deletions x-pack/plugins/reporting/common/schema_utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@ export const durationToNumber = (value: number | moment.Duration): number => {
return value.asMilliseconds();
};

export const numberToDuration = (value: number | moment.Duration): moment.Duration => {
if (typeof value === 'number') {
return moment.duration(value, 'milliseconds');
}
return value;
};

export const byteSizeValueToNumber = (value: number | ByteSizeValue) => {
if (typeof value === 'number') {
return value;
Expand Down
2 changes: 1 addition & 1 deletion x-pack/plugins/reporting/server/core.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export class ReportingCore {
/*
* Register startDeps
*/
public async pluginStart(startDeps: ReportingInternalStart) {
public pluginStart(startDeps: ReportingInternalStart) {
this.pluginStart$.next(startDeps); // trigger the observer
this.pluginStartDeps = startDeps; // cache
}
Expand Down
2 changes: 1 addition & 1 deletion x-pack/plugins/reporting/server/plugin.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ jest.mock('./browsers/install', () => ({
}));

import { coreMock } from 'src/core/server/mocks';
import { featuresPluginMock } from '../../features/server/mocks';
import { ReportingPlugin } from './plugin';
import { createMockConfigSchema } from './test_helpers';
import { featuresPluginMock } from '../../features/server/mocks';

const sleep = (time: number) => new Promise((r) => setTimeout(r, time));

Expand Down
4 changes: 2 additions & 2 deletions x-pack/plugins/reporting/server/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ export class ReportingPlugin

constructor(context: PluginInitializerContext<ReportingConfigType>) {
this.logger = new LevelLogger(context.logger.get());
this.reportingCore = new ReportingCore(this.logger);
this.initializerContext = context;
this.reportingCore = new ReportingCore(this.logger);
}

public setup(core: CoreSetup, plugins: ReportingSetupDeps) {
Expand Down Expand Up @@ -117,7 +117,7 @@ export class ReportingPlugin
const store = new ReportingStore(reportingCore, logger);
const esqueue = await createQueueFactory(reportingCore, store, logger); // starts polling for pending jobs

await reportingCore.pluginStart({
reportingCore.pluginStart({
browserDriverFactory,
savedObjects: core.savedObjects,
uiSettings: core.uiSettings,
Expand Down

0 comments on commit d0ac0bb

Please sign in to comment.