From ac9c5533ec0e92a76e51e324db80193da93007b7 Mon Sep 17 00:00:00 2001 From: Filip Maj Date: Wed, 2 Oct 2024 14:25:00 -0400 Subject: [PATCH] fix refs to combined type utils/helpers --- src/App.ts | 3 +-- src/receivers/AwsLambdaReceiver.ts | 2 +- src/receivers/ExpressReceiver.ts | 2 +- src/receivers/HTTPReceiver.ts | 2 +- src/receivers/SocketModeReceiver.ts | 2 +- src/types/actions/block-action.ts | 2 +- src/types/command/index.ts | 3 +-- src/types/events/index.ts | 3 +-- src/types/middleware.ts | 2 +- src/types/options/index.ts | 3 +-- src/types/receiver.ts | 2 +- 11 files changed, 11 insertions(+), 15 deletions(-) diff --git a/src/App.ts b/src/App.ts index 921c4d260..2e8a4e4e2 100644 --- a/src/App.ts +++ b/src/App.ts @@ -6,7 +6,7 @@ import { Logger, LogLevel, ConsoleLogger } from '@slack/logger'; import axios, { AxiosInstance, AxiosResponse } from 'axios'; import SocketModeReceiver from './receivers/SocketModeReceiver'; import HTTPReceiver, { HTTPReceiverOptions } from './receivers/HTTPReceiver'; -import { isRejected } from './types/utilities'; +import { isRejected, StringIndexed } from './types/utilities'; import { ignoreSelf as ignoreSelfMiddleware, onlyActions, @@ -60,7 +60,6 @@ import { import { IncomingEventType, getTypeAndConversation, assertNever, isBodyWithTypeEnterpriseInstall, isEventTypeToSkipAuthorize } from './helpers'; import { CodedError, asCodedError, AppInitializationError, MultipleListenerError, ErrorCode, InvalidCustomPropertyError } from './errors'; import { AllMiddlewareArgs, contextBuiltinKeys } from './types/middleware'; -import { StringIndexed } from './types/helpers'; import { FunctionCompleteFn, FunctionFailFn, CustomFunction, CustomFunctionMiddleware } from './CustomFunction'; import { Assistant } from './Assistant'; // eslint-disable-next-line @typescript-eslint/no-require-imports, import/no-commonjs diff --git a/src/receivers/AwsLambdaReceiver.ts b/src/receivers/AwsLambdaReceiver.ts index 08253b9ea..6b368aef0 100644 --- a/src/receivers/AwsLambdaReceiver.ts +++ b/src/receivers/AwsLambdaReceiver.ts @@ -6,7 +6,7 @@ import tsscmp from 'tsscmp'; import App from '../App'; import { Receiver, ReceiverEvent } from '../types/receiver'; import { ReceiverMultipleAckError } from '../errors'; -import { StringIndexed } from '../types/helpers'; +import { StringIndexed } from '../types/utilities'; export type AwsEvent = AwsEventV1 | AwsEventV2; type AwsEventStringParameters = Record; diff --git a/src/receivers/ExpressReceiver.ts b/src/receivers/ExpressReceiver.ts index b6618beb3..8f66adf6b 100644 --- a/src/receivers/ExpressReceiver.ts +++ b/src/receivers/ExpressReceiver.ts @@ -19,7 +19,7 @@ import { } from '../errors'; import { AnyMiddlewareArgs, Receiver, ReceiverEvent } from '../types'; import { verifyRedirectOpts } from './verify-redirect-opts'; -import { StringIndexed } from '../types/helpers'; +import { StringIndexed } from '../types/utilities'; import { HTTPModuleFunctions as httpFunc, ReceiverDispatchErrorHandlerArgs, ReceiverProcessEventErrorHandlerArgs, ReceiverUnhandledRequestHandlerArgs } from './HTTPModuleFunctions'; import { HTTPResponseAck } from './HTTPResponseAck'; diff --git a/src/receivers/HTTPReceiver.ts b/src/receivers/HTTPReceiver.ts index c569bd87c..d2911d373 100644 --- a/src/receivers/HTTPReceiver.ts +++ b/src/receivers/HTTPReceiver.ts @@ -17,7 +17,7 @@ import { CodedError, } from '../errors'; import { CustomRoute, buildReceiverRoutes, ReceiverRoutes } from './custom-routes'; -import { StringIndexed } from '../types/helpers'; +import { StringIndexed } from '../types/utilities'; import { BufferedIncomingMessage } from './BufferedIncomingMessage'; import { HTTPModuleFunctions as httpFunc, diff --git a/src/receivers/SocketModeReceiver.ts b/src/receivers/SocketModeReceiver.ts index c8fa1bf7a..97a39d52f 100644 --- a/src/receivers/SocketModeReceiver.ts +++ b/src/receivers/SocketModeReceiver.ts @@ -11,7 +11,7 @@ import { ParamsIncomingMessage } from './ParamsIncomingMessage'; import App from '../App'; import { CodedError } from '../errors'; import { Receiver, ReceiverEvent } from '../types'; -import { StringIndexed } from '../types/helpers'; +import { StringIndexed } from '../types/utilities'; import { buildReceiverRoutes, ReceiverRoutes } from './custom-routes'; import { verifyRedirectOpts } from './verify-redirect-opts'; import { diff --git a/src/types/actions/block-action.ts b/src/types/actions/block-action.ts index 8c1d2b581..2ab61780a 100644 --- a/src/types/actions/block-action.ts +++ b/src/types/actions/block-action.ts @@ -1,5 +1,5 @@ import { PlainTextElement, Confirmation, Option, RichTextBlock } from '@slack/types'; -import { StringIndexed } from '../helpers'; +import { StringIndexed } from '../utilities'; import { ViewOutput, ViewStateValue } from '../view'; /** diff --git a/src/types/command/index.ts b/src/types/command/index.ts index ebd35b4c6..218b51959 100644 --- a/src/types/command/index.ts +++ b/src/types/command/index.ts @@ -1,5 +1,4 @@ -import { StringIndexed } from '../helpers'; -import { SayFn, RespondFn, RespondArguments, AckFn } from '../utilities'; +import { StringIndexed, SayFn, RespondFn, RespondArguments, AckFn } from '../utilities'; /** * Arguments which listeners and middleware receive to process a slash command from Slack. diff --git a/src/types/events/index.ts b/src/types/events/index.ts index eaaf58e34..17e2c62d6 100644 --- a/src/types/events/index.ts +++ b/src/types/events/index.ts @@ -1,6 +1,5 @@ import { SlackEvent } from '@slack/types'; -import { StringIndexed } from '../helpers'; -import { SayFn } from '../utilities'; +import { StringIndexed, SayFn } from '../utilities'; /** * Arguments which listeners and middleware receive to process an event from Slack's Events API. diff --git a/src/types/middleware.ts b/src/types/middleware.ts index d1d8878df..ae4e5538c 100644 --- a/src/types/middleware.ts +++ b/src/types/middleware.ts @@ -1,6 +1,6 @@ import { WebClient } from '@slack/web-api'; import { Logger } from '@slack/logger'; -import { StringIndexed } from './helpers'; +import { StringIndexed } from './utilities'; import { FunctionInputs, SlackEventMiddlewareArgs } from './events'; import { SlackActionMiddlewareArgs } from './actions'; import { SlackCommandMiddlewareArgs } from './command'; diff --git a/src/types/options/index.ts b/src/types/options/index.ts index f0190a0cc..7e3d0ebbb 100644 --- a/src/types/options/index.ts +++ b/src/types/options/index.ts @@ -1,6 +1,5 @@ import { Option, PlainTextElement } from '@slack/types'; -import { StringIndexed, XOR } from '../helpers'; -import { AckFn } from '../utilities'; +import { StringIndexed, XOR, AckFn } from '../utilities'; import { ViewOutput } from '../view/index'; /** diff --git a/src/types/receiver.ts b/src/types/receiver.ts index b790f3e24..e7e8f0932 100644 --- a/src/types/receiver.ts +++ b/src/types/receiver.ts @@ -1,7 +1,7 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ import App from '../App'; import { AckFn } from './index'; -import { StringIndexed } from './helpers'; +import { StringIndexed } from './utilities'; export interface ReceiverEvent { // Parsed HTTP request body / Socket Mode message body