From 1361540de43f582ff2cebe9a5c6031aac0b1ded5 Mon Sep 17 00:00:00 2001 From: hmhealey Date: Tue, 4 Aug 2015 11:30:24 -0400 Subject: Added a date separator before the first post displayed in a channel --- web/react/components/post_list.jsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'web/react/components') diff --git a/web/react/components/post_list.jsx b/web/react/components/post_list.jsx index 3f59d5843..771531b57 100644 --- a/web/react/components/post_list.jsx +++ b/web/react/components/post_list.jsx @@ -311,7 +311,6 @@ module.exports = React.createClass({ } else if (channel.type === 'D') { var teammate = utils.getDirectTeammate(channel.id) - if (teammate) { var teammate_name = teammate.nickname.length > 0 ? teammate.nickname : teammate.username; more_messages = ( @@ -399,7 +398,7 @@ module.exports = React.createClass({ var postCtls = []; if (posts) { - var previousPostDay = posts[order[order.length-1]] ? utils.getDateForUnixTicks(posts[order[order.length-1]].create_at): new Date(); + var previousPostDay = new Date(0); var currentPostDay; for (var i = order.length-1; i >= 0; i--) { -- cgit v1.2.3-1-g7c22