Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions types/meteor/meteor.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -464,6 +464,11 @@ declare module 'meteor/meteor' {
* Access inside the publish function. The incoming connection for this subscription.
*/
stop(): void;
/**
* Call inside the publish function. Allows subsequent methods or subscriptions for the client of this subscription
* to begin running without waiting for the publishing to become ready.
*/
unblock(): void;
/** Access inside the publish function. The id of the logged-in user, or `null` if no user is logged in. */
userId: string | null;
}
Expand Down
2 changes: 2 additions & 0 deletions types/meteor/test/meteor-tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,8 @@ namespace MeteorTests {
// self.added("counts", roomId, {count: count});
self.ready();

self.unblock();

self.onStop(function () {
handle.stop();
});
Expand Down