mirror of
https://github.com/h3poteto/whalebird-desktop
synced 2025-01-11 08:24:58 +01:00
refs #29 Stop old user streaming when start user streaming
This commit is contained in:
parent
1b625d88ae
commit
0b46a736d6
@ -137,6 +137,12 @@ ipcMain.on('start-user-streaming', (event, ac) => {
|
||||
event.sender.send('error-start-user-streaming', err)
|
||||
})
|
||||
.then((account) => {
|
||||
// Stop old user streaming
|
||||
if (userStreaming !== null) {
|
||||
userStreaming.stop()
|
||||
userStreaming = null
|
||||
}
|
||||
|
||||
userStreaming = new Streaming(account)
|
||||
userStreaming.startUserStreaming(
|
||||
(update) => {
|
||||
|
Loading…
Reference in New Issue
Block a user