diff --git a/model/textparse/promparse.go b/model/textparse/promparse.go index f306c03a2a..5aa3bfc1f6 100644 --- a/model/textparse/promparse.go +++ b/model/textparse/promparse.go @@ -446,11 +446,8 @@ func (p *PromParser) parseLVals() error { // Free trailing commas are allowed. NOTE: this allows spaces between label // names, unlike in OpenMetrics. It is not clear if this is intended or an // accidental bug. - t = p.nextToken() - if t == tComma { + if t = p.nextToken(); t == tComma { t = p.nextToken() - } else if t != tBraceClose { - return p.parseError("expected comma or brace close", t) } } }