From b1494cf97f0be084e4c689e63d81d8ba2b4780d4 Mon Sep 17 00:00:00 2001 From: Umputun Date: Sun, 6 May 2018 17:39:31 -0500 Subject: [PATCH] preview sanitize after md reneder --- app/rest/api/rest.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/rest/api/rest.go b/app/rest/api/rest.go index 388d421a..cf871921 100644 --- a/app/rest/api/rest.go +++ b/app/rest/api/rest.go @@ -165,8 +165,8 @@ func (s *Rest) previewCommentCtrl(w http.ResponseWriter, r *http.Request) { return } - comment.Sanitize() comment.Text = string(blackfriday.Run([]byte(comment.Text), blackfriday.WithExtensions(mdExt))) + comment.Sanitize() render.HTML(w, r, comment.Text) }