neilenns / streamdeck-trackaudio

Stream Deck buttons for controlling TrackAudio
MIT License
6 stars 1 forks source link

Use generics to remove code duplication #245

Closed neilenns closed 2 months ago

neilenns commented 2 months ago

There's a lot of copy/paste code in the action manager class to return arrays of specific controller types. Use generics to write a general purpose getControllers function that takes a typeguard, then use that in each of the controller type functions.