Skip to content

Commit

Permalink
Merge pull request hashicorp#176 from theherk/feature/build-on-Go-bef…
Browse files Browse the repository at this point in the history
…ore-1.7

Modify new bytes.ContainsRune to backward compatible bytes.IndexRune
  • Loading branch information
mitchellh committed Dec 15, 2016
2 parents 37ab263 + f3dd3ed commit 80e628d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hcl/printer/nodes.go
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ func (p *printer) literalType(lit *ast.LiteralType) []byte {
case token.STRING:
// If this is a multiline string, poison lines 2+ so we don't
// indent them.
if bytes.ContainsRune(result, '\n') {
if bytes.IndexRune(result, '\n') >= 0 {
result = p.heredocIndent(result)
}
}
Expand Down

0 comments on commit 80e628d

Please sign in to comment.