From 987877771eddef8b4a6f9ee406ce8c9a3462efee Mon Sep 17 00:00:00 2001 From: kortschak Date: Thu, 8 Jun 2017 09:28:27 +0930 Subject: [PATCH] x/tools/present: fix element number check Fixes golang/go#20605 Change-Id: Ia87097741b743d9b138f0f16540d601b9525c7de Reviewed-on: https://go-review.googlesource.com/45110 Reviewed-by: Andrew Gerrand --- present/link.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/present/link.go b/present/link.go index 5885eb14..2aead352 100644 --- a/present/link.go +++ b/present/link.go @@ -24,7 +24,7 @@ func (l Link) TemplateName() string { return "link" } func parseLink(ctx *Context, fileName string, lineno int, text string) (Elem, error) { args := strings.Fields(text) - if len(args) < 3 { + if len(args) < 2 { return nil, fmt.Errorf("link element must have at least 2 arguments") } url, err := url.Parse(args[1])