feat: Implement notification settings and logic for new video versions.

This commit is contained in:
Yusuf İpek
2026-02-20 13:51:00 +03:00
parent cdd46cf05e
commit fe496b7fa5
5 changed files with 60 additions and 0 deletions
+4
View File
@@ -26,6 +26,7 @@ export async function GET() {
telegramEnabled: false,
emailEnabled: false,
onNewVideo: true,
onNewVersion: true,
onNewComment: true,
onNewReply: true,
timezone: 'UTC',
@@ -57,6 +58,7 @@ export async function PUT(request: NextRequest) {
telegramEnabled,
emailEnabled,
onNewVideo,
onNewVersion,
onNewComment,
onNewReply,
timezone,
@@ -76,6 +78,7 @@ export async function PUT(request: NextRequest) {
telegramEnabled: !!telegramEnabled,
emailEnabled: !!emailEnabled,
onNewVideo: onNewVideo ?? true,
onNewVersion: onNewVersion ?? true,
onNewComment: onNewComment ?? true,
onNewReply: onNewReply ?? true,
timezone: timezone || 'UTC',
@@ -86,6 +89,7 @@ export async function PUT(request: NextRequest) {
telegramEnabled: !!telegramEnabled,
emailEnabled: !!emailEnabled,
onNewVideo: onNewVideo ?? true,
onNewVersion: onNewVersion ?? true,
onNewComment: onNewComment ?? true,
onNewReply: onNewReply ?? true,
timezone: timezone || 'UTC',