summaryrefslogtreecommitdiffstats
path: root/web/react/components/post_right.jsx
diff options
context:
space:
mode:
authorChristopher Speller <crspeller@gmail.com>2015-07-13 14:36:27 -0400
committerChristopher Speller <crspeller@gmail.com>2015-07-13 14:36:27 -0400
commite38ea318a1287710313a0c86fecb76dff8a923aa (patch)
tree79a5158a3036563eb45852293f0c5a4af1a196b7 /web/react/components/post_right.jsx
parentd2602f540c953ffea2e622ed4c699ab44eadd087 (diff)
parentaff43f43f8185ae6d5555ca9f99bfcc4bd3eb99e (diff)
downloadchat-e38ea318a1287710313a0c86fecb76dff8a923aa.tar.gz
chat-e38ea318a1287710313a0c86fecb76dff8a923aa.tar.bz2
chat-e38ea318a1287710313a0c86fecb76dff8a923aa.zip
Merge pull request #158 from nickago/MM-975
MM-975 Added timestamps to pictures to stop caching
Diffstat (limited to 'web/react/components/post_right.jsx')
-rw-r--r--web/react/components/post_right.jsx6
1 files changed, 4 insertions, 2 deletions
diff --git a/web/react/components/post_right.jsx b/web/react/components/post_right.jsx
index 115ee87d4..408fbf83a 100644
--- a/web/react/components/post_right.jsx
+++ b/web/react/components/post_right.jsx
@@ -67,6 +67,7 @@ RootPost = React.createClass({
var message = utils.textToJsx(this.props.post.message);
var filenames = this.props.post.filenames;
var isOwner = UserStore.getCurrentId() == this.props.post.user_id;
+ var timestamp = UserStore.getProfile(this.props.post.user_id).update_at;
var type = "Post";
if (this.props.post.root_id.length > 0) {
@@ -118,7 +119,7 @@ RootPost = React.createClass({
return (
<div className={"post post--root " + currentUserCss}>
<div className="post-profile-img__container">
- <img className="post-profile-img" src={"/api/v1/users/" + this.props.post.user_id + "/image"} height="36" width="36" />
+ <img className="post-profile-img" src={"/api/v1/users/" + this.props.post.user_id + "/image?time=" + timestamp} height="36" width="36" />
</div>
<div className="post__content">
<ul className="post-header">
@@ -227,11 +228,12 @@ CommentPost = React.createClass({
}
var message = utils.textToJsx(this.props.post.message);
+ var timestamp = UserStore.getCurrentUser().update_at;
return (
<div className={commentClass + " " + currentUserCss}>
<div className="post-profile-img__container">
- <img className="post-profile-img" src={"/api/v1/users/" + this.props.post.user_id + "/image"} height="36" width="36" />
+ <img className="post-profile-img" src={"/api/v1/users/" + this.props.post.user_id + "/image?time=" + timestamp} height="36" width="36" />
</div>
<div className="post__content">
<ul className="post-header">