From 92816619cc584c7c172c4e4fdde17624cf7f913f Mon Sep 17 00:00:00 2001
From: Reed Garmsen <rgarmsen2295@gmail.com>
Date: Mon, 1 Feb 2016 14:30:16 -0800
Subject: Changed clock icon in repeat posts to simple timestamp

---
 web/react/components/time_since.jsx | 17 ++++++++++++++---
 1 file changed, 14 insertions(+), 3 deletions(-)

(limited to 'web/react/components/time_since.jsx')

diff --git a/web/react/components/time_since.jsx b/web/react/components/time_since.jsx
index 32947bd60..0b549b1e6 100644
--- a/web/react/components/time_since.jsx
+++ b/web/react/components/time_since.jsx
@@ -14,7 +14,7 @@ export default class TimeSince extends React.Component {
     componentDidMount() {
         this.intervalId = setInterval(() => {
             this.forceUpdate();
-        }, 30000);
+        }, Constants.TIME_SINCE_UPDATE_INTERVAL);
     }
     componentWillUnmount() {
         clearInterval(this.intervalId);
@@ -23,6 +23,14 @@ export default class TimeSince extends React.Component {
         const displayDate = Utils.displayDate(this.props.eventTime);
         const displayTime = Utils.displayTime(this.props.eventTime);
 
+        if (this.props.sameUser) {
+            return (
+                <time className='post__time'>
+                    {Utils.displayTime(this.props.eventTime)}
+                </time>
+            );
+        }
+
         const tooltip = (
             <Tooltip id={'time-since-tooltip-' + this.props.eventTime}>
                 {displayDate + ' at ' + displayTime}
@@ -42,10 +50,13 @@ export default class TimeSince extends React.Component {
         );
     }
 }
+
 TimeSince.defaultProps = {
-    eventTime: 0
+    eventTime: 0,
+    sameUser: false
 };
 
 TimeSince.propTypes = {
-    eventTime: React.PropTypes.number.isRequired
+    eventTime: React.PropTypes.number.isRequired,
+    sameUser: React.PropTypes.bool
 };
-- 
cgit v1.2.3-1-g7c22

