From e4effd0c15a188eeec7a11f281e529afd6a54f80 Mon Sep 17 00:00:00 2001 From: Joram Wilander Date: Mon, 13 Feb 2017 10:52:50 -0500 Subject: Implement some post endpoints for APIv4 (#5353) * Implement POST /posts endpoint for APIv4 * Implement GET /channels/{channel_id}/posts endpoint for APIv4 * Implement GET /posts/{post_id} endpoint for APIv4 * Implement GET /posts/{post_id}/thread endpoint for APIv4 * Skip team get if it's a DM channel in handlePostEvents --- model/post_list.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'model/post_list.go') diff --git a/model/post_list.go b/model/post_list.go index 4c0f5408e..5a479ca35 100644 --- a/model/post_list.go +++ b/model/post_list.go @@ -75,7 +75,12 @@ func (o *PostList) Etag() string { } } - return Etag(id, t) + orderId := "" + if len(o.Order) > 0 { + orderId = o.Order[0] + } + + return Etag(orderId, id, t) } func (o *PostList) IsChannelId(channelId string) bool { -- cgit v1.2.3-1-g7c22