mirror of
https://github.com/svemagie/indiekit-endpoint-youtube.git
synced 2026-04-02 15:54:59 +02:00
fix: simplify like post content and create as draft
Content is now "Title - Author" instead of "Liked X by Y on YouTube". Posts are created with post-status: draft so they can be reviewed before publishing. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -169,15 +169,15 @@ export async function syncLikes({ db, youtubeConfig, publication, postsCollectio
|
||||
"post-type": "like",
|
||||
"mp-slug": slug,
|
||||
"like-of": videoUrl,
|
||||
name: `Liked "${video.title}" by ${video.channelTitle}`,
|
||||
name: `${video.title} - ${video.channelTitle}`,
|
||||
content: {
|
||||
text: `Liked "${video.title}" by ${video.channelTitle} on YouTube`,
|
||||
html: `Liked "<a href="${videoUrl}">${escapeHtml(video.title)}</a>" by ${escapeHtml(video.channelTitle)} on YouTube`,
|
||||
text: `${video.title} - ${video.channelTitle}`,
|
||||
html: `<a href="${videoUrl}">${escapeHtml(video.title)}</a> - ${escapeHtml(video.channelTitle)}`,
|
||||
},
|
||||
published: new Date().toISOString(),
|
||||
url: postUrl,
|
||||
visibility: "public",
|
||||
"post-status": "published",
|
||||
"post-status": "draft",
|
||||
"youtube-video-id": videoId,
|
||||
"youtube-channel": video.channelTitle,
|
||||
"youtube-thumbnail": video.thumbnail || "",
|
||||
|
||||
Reference in New Issue
Block a user