3 ms·
When receiving from a channel, it is possible to receive a second argument. This second argument is a `bool` and it resolves to `false` when the channel is clos
by ihsw2 9y ago
When receiving from a channel, it is possible to receive a second argument. This second argument is a `bool` and it resolves to `false` when the channel is closed. This removes the need for a `cancelChan` channel that your worker handles.