When I first implemented the voice gateway, I (pretty foolishly) just copy-pasted the code for the regular gateway backends, with some type changes. Now I've thought of a pretty easy to way to have the websocket backends implemented in just one place, so they aren't duplicated. (also because there is potentially another type of gateway to implement, and maintaining the same code three times would be a pain)
When I first implemented the voice gateway, I (pretty foolishly) just copy-pasted the code for the regular gateway backends, with some type changes. Now I've thought of a pretty easy to way to have the websocket backends implemented in just one place, so they aren't duplicated. (also because there is potentially another type of gateway to implement, and maintaining the same code three times would be a pain)