feat(summary): send complete articles within user budget (#39)
This commit is contained in:
11
backend/internal/scraper/yahoofinance/content.go
Normal file
11
backend/internal/scraper/yahoofinance/content.go
Normal file
@ -0,0 +1,11 @@
|
||||
package yahoofinance
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/tradarr/backend/internal/scraper"
|
||||
"github.com/tradarr/backend/internal/scraper/articlecontent"
|
||||
)
|
||||
|
||||
func (y *YahooFinance) Enrich(ctx context.Context, articles []scraper.Article) ([]scraper.Article, error) {
|
||||
return articlecontent.Enrich(ctx, y.client, "yahoo_finance", articles)
|
||||
}
|
||||
@ -131,7 +131,7 @@ func (y *YahooFinance) fetchSymbol(ctx context.Context, symbol string) (articles
|
||||
content = title
|
||||
}
|
||||
|
||||
articles = append(articles, scraper.Article{
|
||||
articles = append(articles, scraper.Article{ContentState: scraper.ContentIncomplete,
|
||||
Title: title,
|
||||
Content: content,
|
||||
URL: link,
|
||||
|
||||
Reference in New Issue
Block a user