@@ -88,7 +88,7 @@ class NotificationHelper(val context: Context) {
8888
8989 // Show individual stream notifications, set channel icon only if there is actually
9090 // one
91- showStreamNotifications(newStreams, data.serviceId, bitmap)
91+ showStreamNotifications(newStreams, data.serviceId, data.url, bitmap)
9292 // Show summary notification
9393 manager.notify(data.pseudoId, summaryBuilder.build())
9494
@@ -97,7 +97,7 @@ class NotificationHelper(val context: Context) {
9797
9898 override fun onBitmapFailed (e : Exception , errorDrawable : Drawable ) {
9999 // Show individual stream notifications
100- showStreamNotifications(newStreams, data.serviceId, null )
100+ showStreamNotifications(newStreams, data.serviceId, data.url, null )
101101 // Show summary notification
102102 manager.notify(data.pseudoId, summaryBuilder.build())
103103 iconLoadingTargets.remove(this ) // allow it to be garbage-collected
@@ -118,17 +118,19 @@ class NotificationHelper(val context: Context) {
118118 private fun showStreamNotifications (
119119 newStreams : List <StreamInfoItem >,
120120 serviceId : Int ,
121+ channelUrl : String ,
121122 channelIcon : Bitmap ?
122123 ) {
123124 for (stream in newStreams) {
124- val notification = createStreamNotification(stream, serviceId, channelIcon)
125+ val notification = createStreamNotification(stream, serviceId, channelUrl, channelIcon)
125126 manager.notify(stream.url.hashCode(), notification)
126127 }
127128 }
128129
129130 private fun createStreamNotification (
130131 item : StreamInfoItem ,
131132 serviceId : Int ,
133+ channelUrl : String ,
132134 channelIcon : Bitmap ?
133135 ): Notification {
134136 return NotificationCompat .Builder (
@@ -139,7 +141,7 @@ class NotificationHelper(val context: Context) {
139141 .setLargeIcon(channelIcon)
140142 .setContentTitle(item.name)
141143 .setContentText(item.uploaderName)
142- .setGroup(item.uploaderUrl )
144+ .setGroup(channelUrl )
143145 .setColor(ContextCompat .getColor(context, R .color.ic_launcher_background))
144146 .setColorized(true )
145147 .setAutoCancel(true )
0 commit comments