chanage bug

This commit is contained in:
sylor_huang@126.com 2020-06-05 18:39:46 +08:00
parent 6fc93489ab
commit c337e0c558
1 changed files with 9 additions and 6 deletions

View File

@ -1,8 +1,11 @@
# user = target.watchable
unless user.id === current_user.try(:id)
json.format_time target.created_at.strftime("%Y-%m-%d")
json.name user.try(:show_real_name)
json.login user.try(:login)
json.image_url url_to_avatar(user)
json.is_current_user current_user.try(:id) == target.user_id
json.is_watch current_user&.watched?(user)
end
json.format_time target.created_at.strftime("%Y-%m-%d")
json.name user.try(:show_real_name)
json.login user.try(:login)
json.image_url url_to_avatar(user)
json.is_current_user current_user.try(:id) == target.user_id
json.is_watch current_user&.watched?(user)