Skip to content

Commit

Permalink
clean up async
Browse files Browse the repository at this point in the history
  • Loading branch information
tsullivan committed Apr 2, 2020
1 parent 4dbb30e commit 5bf7d13
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions x-pack/legacy/plugins/reporting/server/lib/enqueue_job.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,7 @@ interface ConfirmedJob {
_primary_term: number;
}

export async function enqueueJobFactory(
reporting: ReportingCore,
parentLogger: Logger
): Promise<EnqueueJobFn> {
export function enqueueJobFactory(reporting: ReportingCore, parentLogger: Logger): EnqueueJobFn {
const config = reporting.getConfig();
const logger = parentLogger.clone(['queue-job']);
const captureConfig = config.get('capture');
Expand Down
2 changes: 1 addition & 1 deletion x-pack/legacy/plugins/reporting/server/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export class ReportingPlugin
const { reportingCore, logger } = this;

const esqueue = await createQueueFactory(reportingCore, logger);
const enqueueJob = await enqueueJobFactory(reportingCore, logger);
const enqueueJob = enqueueJobFactory(reportingCore, logger);

this.reportingCore.pluginStart({
savedObjects: core.savedObjects,
Expand Down

0 comments on commit 5bf7d13

Please sign in to comment.