diff --git a/terraform/parser.go b/terraform/parser.go index 9dace47..938afc4 100644 --- a/terraform/parser.go +++ b/terraform/parser.go @@ -90,7 +90,7 @@ func (p *DefaultParser) Parse(body string) ParseResult { func (p *FmtParser) Parse(body string) ParseResult { result := ParseResult{} if p.Fail.MatchString(body) { - result.Result = body + result.Result = "There is diff in your .tf file (need to be formatted)" result.ExitCode = ExitFail } return result diff --git a/terraform/template.go b/terraform/template.go index 5387471..848e6dd 100644 --- a/terraform/template.go +++ b/terraform/template.go @@ -241,8 +241,8 @@ func (t *FmtTemplate) Execute() (string, error) { data := map[string]interface{}{ "Title": t.Title, "Message": t.Message, - "Result": "", - "Body": t.Result, + "Result": t.Result, + "Body": t.Body, "Link": t.Link, }