Add library tags variable to podcast notifications

This commit is contained in:
Philipp Rintz 2023-02-14 16:41:58 +01:00 committed by GitHub
parent 481611ff33
commit 7207efb4da
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -24,6 +24,7 @@ class NotificationManager {
libraryItemId: libraryItem.id,
libraryId: libraryItem.libraryId,
libraryName: library ? library.name : 'Unknown',
libraryTags: libraryItem.tags,
podcastTitle: libraryItem.media.metadata.title,
episodeId: episode.id,
episodeTitle: episode.title

View File

@ -7,8 +7,7 @@ module.exports.notificationData = {
requiresLibrary: true,
libraryMediaType: 'podcast',
description: 'Triggered when a podcast episode is auto-downloaded',
variables: ['libraryItemId', 'libraryId', 'podcastTitle', 'episodeTitle', 'libraryName', 'episodeId'],
defaults: {
variables: ['libraryItemId', 'libraryId', 'podcastTitle', 'episodeTitle', 'libraryName', 'episodeId', 'libraryTags'], defaults: {
title: 'New {{podcastTitle}} Episode!',
body: '{{episodeTitle}} has been added to {{libraryName}} library.'
},
@ -16,6 +15,7 @@ module.exports.notificationData = {
libraryItemId: 'li_notification_test',
libraryId: 'lib_test',
libraryName: 'Podcasts',
libraryTags: ['TestTag1', 'TestTag2'],
podcastTitle: 'Abs Test Podcast',
episodeId: 'ep_notification_test',
episodeTitle: 'Successful Test'