From e7725106ed5b435c625a63691d99acc197a2106a Mon Sep 17 00:00:00 2001 From: Chris Date: Tue, 5 Dec 2017 13:18:45 -0600 Subject: fix post editing when channel links are present (#7938) --- app/post.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/post.go') diff --git a/app/post.go b/app/post.go index 0bd3b654f..192c2effb 100644 --- a/app/post.go +++ b/app/post.go @@ -207,7 +207,7 @@ func (a *App) FillInPostProps(post *model.Post, channel *model.Channel) *model.A if len(channelMentions) > 0 { if channel == nil { result := <-a.Srv.Store.Channel().GetForPost(post.Id) - if result.Err == nil { + if result.Err != nil { return model.NewAppError("FillInPostProps", "api.context.invalid_param.app_error", map[string]interface{}{"Name": "post.channel_id"}, result.Err.Error(), http.StatusBadRequest) } channel = result.Data.(*model.Channel) -- cgit v1.2.3-1-g7c22