Web-Multi-Media / multi-web-audio-sequencer

Web collaborative step sequencer
https://labs.freesound.org/sequencer
GNU General Public License v3.0
10 stars 2 forks source link

Bug socket deco/reco #17

Closed xavierfav closed 6 years ago

xavierfav commented 6 years ago

It appends that sometimes the server re-send the sequencer state to the clients, making them to create duplicate of the tracks. This comes maybe from a connexion and re-connexion of the socket.

This could be solve by checking if the tracks already exist when receiving the state from the server, and then decide if it is needed to delete and recreate them, or simply not do anything.

The trackNameExist function will be useful for checking if tracks already exist.

xavierfav commented 6 years ago

This has been solved in #23. When receiving a sequencer state, the client check if the numbers of tracks are the same locally and in the received state. If they are the same, it does nothing, if they are different, tracks are locally deleted and then the sequencer state is loaded.