summaryrefslogtreecommitdiff
path: root/href.go
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2016-12-20 23:18:45 +0100
committerDimitri Sokolyuk <demon@dim13.org>2016-12-20 23:18:45 +0100
commita037c25326bceabc471f679ab2203d99e248ab0e (patch)
tree629afc9ef6db05fdf3b5d86a9ecb1259ccebbe93 /href.go
parent9b70cb6996a7b9e151e23dc9e49cc8a1114391d5 (diff)
maxLen
Diffstat (limited to 'href.go')
-rw-r--r--href.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/href.go b/href.go
index e1a687b..918a2f2 100644
--- a/href.go
+++ b/href.go
@@ -13,6 +13,8 @@ import (
var errNotHTML = errors.New("not HTML content")
+const maxLen = 500
+
func title(n *html.Node) (s string) {
if n.Type == html.ElementNode && n.Data == "title" {
for c := n.FirstChild; c != nil; c = c.NextSibling {