Skip to content

Commit 1140484

Browse files
committed
add subscription check
1 parent aa91cd5 commit 1140484

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/LiveQuery/ParseLiveQueryServer.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1083,6 +1083,12 @@ class ParseLiveQueryServer {
10831083
}
10841084

10851085
const { subscription } = subscriptionInfo;
1086+
if (!subscription) {
1087+
Client.pushError(parseWebsocket, 2, 'Subscription not found for requestId ' + requestId);
1088+
logger.error('Subscription not found for requestId ' + requestId);
1089+
return;
1090+
}
1091+
10861092
const { className, query } = subscription;
10871093

10881094
try {

0 commit comments

Comments
 (0)