Fix error display for previously failed but now successful posts

Update schedulerService.publishPost to clear the error field when a post is successfully republished.

Replit-Commit-Author: Agent
Replit-Commit-Session-Id: ae4037a0-2a6f-4530-9bac-79b543286bda
Replit-Commit-Checkpoint-Type: full_checkpoint
Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/397bca8c-984f-43ff-841a-10897aeb8140/ae4037a0-2a6f-4530-9bac-79b543286bda/VDgoPyA
This commit is contained in:
michaelschal committed 2025-10-14 19:10:26 +00:00
1 parent 1f94d76743
commit 1c0e24ece7
2 files changed
+3 -1

No files matched your search

+2 -1
View File
@@ -112,10 +112,11 @@ export class SchedulerService {
throw new Error(`Unsupported platform: ${page.platform}`);
}
// Update the scheduled post as published
// Update the scheduled post as published (clear any previous error)
await storage.updateScheduledPost(scheduledPost.id, {
publishedAt: new Date(),
externalPostId,
error: null,
});
// Update post status