Rename atom.GetFromHTML to atom.GetFromString, as compatibility is determined by user regex

This commit is contained in:
2026-01-04 13:54:53 -05:00
parent bcbf59a98b
commit 8a63e50228
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -28,10 +28,10 @@ type IndicesT struct {
AuthorEmailI []int8
}
func GetFromHTML(feed *feeds.Feed, rawHTML *string, regexString string, infoIndices IndicesT, maxFeedItems int) (*string, error) {
func GetFromString(feed *feeds.Feed, input *string, regexString string, infoIndices IndicesT, maxFeedItems int) (*string, error) {
now := time.Now()
r := regexp.MustCompile(regexString)
newsItems := r.FindAllString(*rawHTML, maxFeedItems)
newsItems := r.FindAllString(*input, maxFeedItems)
for i, item := range newsItems {
info := r.FindStringSubmatch(item)
link := stitchFields(info, infoIndices.LinkC, infoIndices.LinkI)