Skip to content

Commit

Permalink
fix: Fixing construction of the EngageActionPerformer.
Browse files Browse the repository at this point in the history
  • Loading branch information
cogwizzle committed Jun 6, 2024
1 parent e758ce1 commit 631df68
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable @typescript-eslint/no-explicit-any */
import { RequestClient } from '@segment/actions-core/create-request-client'
import { ExecuteInput } from '@segment/actions-core/destination-kit'
import { EngageDestinationCache, ExecuteInput } from '@segment/actions-core/destination-kit'
import { MaybePromise } from '@segment/actions-core/destination-kit/types'
import { EngageLogger } from './EngageLogger'
import { EngageStats } from './EngageStats'
Expand All @@ -19,7 +19,7 @@ import truncate from 'lodash/truncate'
export abstract class EngageActionPerformer<TSettings = any, TPayload = any, TReturn = any> {
readonly logger: EngageLogger = new EngageLogger(this)
readonly statsClient: EngageStats = new EngageStats(this)
readonly engageDestinationCache = this.executeInput.engageDestinationCache
readonly engageDestinationCache: EngageDestinationCache | undefined
readonly currentOperation: OperationContext | undefined

readonly payload: TPayload
Expand All @@ -28,6 +28,7 @@ export abstract class EngageActionPerformer<TSettings = any, TPayload = any, TRe
constructor(readonly requestClient: RequestClient, readonly executeInput: ExecuteInput<TSettings, TPayload>) {
this.payload = executeInput.payload
this.settings = executeInput.settings
this.engageDestinationCache = executeInput.engageDestinationCache
}

beforePerform?(): void | Promise<void>
Expand Down

0 comments on commit 631df68

Please sign in to comment.