summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorReed Garmsen <rgarmsen2295@gmail.com>2015-08-24 12:58:04 -0700
committerReed Garmsen <rgarmsen2295@gmail.com>2015-08-24 12:58:04 -0700
commitb2c16401c80327f333ff61130593b7a2d3d0b640 (patch)
tree1b25846f8e4d46db9c1b9a6708f0414313234bb8
parent192e18cdd0f2f87c3d932de003ed59cc6ca372ba (diff)
downloadchat-b2c16401c80327f333ff61130593b7a2d3d0b640.tar.gz
chat-b2c16401c80327f333ff61130593b7a2d3d0b640.tar.bz2
chat-b2c16401c80327f333ff61130593b7a2d3d0b640.zip
Fixed issue with site tryinng to load profile pictures without having profile information
-rw-r--r--web/react/components/post.jsx7
1 files changed, 6 insertions, 1 deletions
diff --git a/web/react/components/post.jsx b/web/react/components/post.jsx
index 53ffeb400..cc2e37fa8 100644
--- a/web/react/components/post.jsx
+++ b/web/react/components/post.jsx
@@ -102,7 +102,12 @@ module.exports = React.createClass({
currentUserCss = "current--user";
}
- var timestamp = UserStore.getProfile(post.user_id).update_at;
+ var userProfile = UserStore.getProfile(post.user_id);
+
+ var timestamp = UserStore.getCurrentUser().update_at;
+ if (userProfile) {
+ timestamp = userProfile.update_at;
+ }
return (
<div>