Skip to content

Commit 4a20e8c

Browse files
committed
fix: revert awaits
1 parent 23a8782 commit 4a20e8c

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/RedisQueue.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ export class RedisQueue extends EventEmitter<EventMap>
348348
this.verbose('Initialize unsubscribing...');
349349

350350
if (this.subscriptionName) {
351-
await this.subscription.unsubscribe(
351+
this.subscription.unsubscribe(
352352
`${this.options.prefix}:${this.subscriptionName}`,
353353
);
354354

@@ -358,7 +358,7 @@ export class RedisQueue extends EventEmitter<EventMap>
358358

359359
this.subscription.removeAllListeners();
360360
this.subscription.disconnect(false);
361-
await this.subscription.quit();
361+
this.subscription.quit();
362362
}
363363

364364
this.subscriptionName = undefined;
@@ -510,7 +510,7 @@ export class RedisQueue extends EventEmitter<EventMap>
510510
};
511511

512512
if (delay) {
513-
await this.writer.zadd(`${key}:delayed`, Date.now() + delay, packet,
513+
this.writer.zadd(`${key}:delayed`, Date.now() + delay, packet,
514514
(err: any) => {
515515
// istanbul ignore next
516516
if (err) {
@@ -531,7 +531,7 @@ export class RedisQueue extends EventEmitter<EventMap>
531531
).catch((err: any) => cb(err, 'SET'));
532532
});
533533
} else {
534-
await this.writer.lpush(key, packet, (err: any) => {
534+
this.writer.lpush(key, packet, (err: any) => {
535535
// istanbul ignore next
536536
if (err) {
537537
cb(err, 'LPUSH');
@@ -556,7 +556,7 @@ export class RedisQueue extends EventEmitter<EventMap>
556556
if (this.reader) {
557557
this.verbose('Destroying reader...');
558558
this.reader.removeAllListeners();
559-
await this.reader.quit();
559+
this.reader.quit();
560560
this.reader.disconnect(false);
561561

562562
delete this.reader;
@@ -1135,7 +1135,7 @@ export class RedisQueue extends EventEmitter<EventMap>
11351135
*/
11361136
private async onWatchMessage(...args: any[]): Promise<void> {
11371137
try {
1138-
const key = ((args.pop() || '') + '').split(':');
1138+
const key = (args.pop() || '').split(':');
11391139

11401140
if (key.pop() !== 'ttl') {
11411141
return;

0 commit comments

Comments
 (0)