MCPcopy Create free account
hub / github.com/MMadmer/EpicAssetsNotifyBot / parseAttributes

Function parseAttributes

internal/fab/scraper.go:341–350  ·  view source on GitHub ↗
(input string, pattern *regexp.Regexp)

Source from the content-addressed store, hash-verified

339}
340
341func parseAttributes(input string, pattern *regexp.Regexp) map[string]string {
342 attributes := make(map[string]string)
343 for _, match := range pattern.FindAllStringSubmatch(input, -1) {
344 if len(match) < 3 {
345 continue
346 }
347 attributes[strings.ToLower(match[1])] = html.UnescapeString(match[2])
348 }
349 return attributes
350}
351
352func normalizeImageURL(url string) string {
353 if url == "" {

Callers 1

parseAssetsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected