Vulcan/client/templates/user_profile.js
2012-09-24 22:27:29 +02:00

20 lines
No EOL
492 B
JavaScript

Template.user_profile.user = function(){
if(window.selected_user_id){
return Meteor.users.findOne(window.selected_user_id);
}
}
Template.user_profile.avatar_url = function(){
return Gravatar.getGravatar(this, {
d: 'http://telescope.herokuapp.com/img/default_avatar.png',
s: 80
});
}
Template.user_profile.created_at_formatted = Template.user_item.created_at_formatted;
Template.user_profile.is_current_user = function(){
return (window.selected_user_id === current_user_id);
}