Skip to content

Commit 52ee093

Browse files
cleanup
1 parent 146ea1a commit 52ee093

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

lib/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,24 +52,24 @@ async function createQueue(
5252
sqsClient: SQS,
5353
opts: AdapterOptions
5454
) {
55-
const topicName = opts?.topicName || "socket-io";
55+
const topicName = opts.topicName || "socket-io";
5656

5757
debug("creating topic [%s]", topicName);
5858

5959
const createTopicCommandOutput = await snsClient.createTopic({
6060
Name: topicName,
61-
Tags: opts?.topicTags,
61+
Tags: opts.topicTags,
6262
});
6363

6464
debug("topic [%s] was successfully created", topicName);
6565

66-
const queueName = `${opts?.queuePrefix || "socket-io"}-${randomId()}`;
66+
const queueName = `${opts.queuePrefix || "socket-io"}-${randomId()}`;
6767

6868
debug("creating queue [%s]", queueName);
6969

7070
const createQueueCommandOutput = await sqsClient.createQueue({
7171
QueueName: queueName,
72-
tags: opts?.queueTags,
72+
tags: opts.queueTags,
7373
});
7474

7575
debug("queue [%s] was successfully created", queueName);
@@ -140,7 +140,7 @@ async function createQueue(
140140
export function createAdapter(
141141
snsClient: SNS,
142142
sqsClient: SQS,
143-
opts: AdapterOptions & ClusterAdapterOptions
143+
opts: AdapterOptions & ClusterAdapterOptions = {}
144144
) {
145145
let isClosed = false;
146146
let _topicArn: string;

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)