Get feed item now will preload feed

This commit is contained in:
2025-04-06 13:23:07 +08:00
parent c812359f8b
commit fd0d3699e4
2 changed files with 3 additions and 1 deletions

View File

@ -11,6 +11,7 @@ func GetTodayFeedRandomly(limit int) ([]models.SubscriptionItem, error) {
Where("DATE(created_at) = CURRENT_DATE"). // Created in today
Order("RANDOM()").
Omit("Content").
Preload("Feed").
Find(&articles).Error; err != nil {
return articles, err
}