public ListingsController(
     SearchByName searchByNameQuery,
     ChannelIcon channelIconQuery,
     NowPlaying nowPlayingQuery)
 {
     _searchByNameQuery = searchByNameQuery;
     _channelIconQuery = channelIconQuery;
     _nowPlayingQuery = nowPlayingQuery;
 }
        public string UpdateChannelGroupIcon(IDbConnection connection, string newBase64SourceImage, int channelId, int adminUserId, string ext = null)
        {
            var channel = _channelRepo.GetById(connection, channelId);

            if (channel.creatorId != adminUserId)
            {
                throw new SecurityException(Error.NotPermitted);
            }
            var newUrl = ChannelIcon.CreateFromB64(newBase64SourceImage, channelId, ext);

            channel.channelIcon = newUrl;
            _channelRepo.Update(connection, channel);
            return(newUrl);
        }