include attachment name and URL in broadcast intents

This commit is contained in:
Hunter Kehoe 2022-06-16 21:01:12 -06:00
parent d3806ea347
commit 658efc8ece

View file

@ -33,6 +33,8 @@ class BroadcastService(private val ctx: Context) {
intent.putExtra("priority", notification.priority) intent.putExtra("priority", notification.priority)
intent.putExtra("muted", muted) intent.putExtra("muted", muted)
intent.putExtra("muted_str", muted.toString()) intent.putExtra("muted_str", muted.toString())
intent.putExtra("attachment_name", notification.attachment?.name)
intent.putExtra("attachment_url", notification.attachment?.url)
Log.d(TAG, "Sending message intent broadcast: ${intent.action} with extras ${intent.extras}") Log.d(TAG, "Sending message intent broadcast: ${intent.action} with extras ${intent.extras}")
ctx.sendBroadcast(intent) ctx.sendBroadcast(intent)