Changed the whole logic that returns the available channels to the UI
some small change for the ui