Skip to content
This repository was archived by the owner on Feb 7, 2024. It is now read-only.

Commit 3cf74c7

Browse files
authored
Merge pull request #708 from simonbuehler/master
[2.x] Fix unsubscribeFromAllChannels leaving stale connections
2 parents efb3aa8 + 0dc2db1 commit 3cf74c7

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/ChannelManagers/LocalChannelManager.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,10 @@ public function unsubscribeFromAllChannels(ConnectionInterface $connection): Pro
173173

174174
$this->getLocalChannels($connection->app->id)
175175
->then(function ($channels) use ($connection) {
176-
collect($channels)->each->unsubscribe($connection);
176+
collect($channels)
177+
->each(function (Channel $channel) use ($connection) {
178+
$channel->unsubscribe($connection);
179+
});
177180

178181
collect($channels)
179182
->reject->hasConnections()

0 commit comments

Comments
 (0)