Browse Source

#61

feature/061
みてるぞ 1 week ago
parent
commit
cac4ad7f51
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      backend/app/representations/post_repr.rb

+ 1
- 1
backend/app/representations/post_repr.rb View File

@@ -8,7 +8,7 @@ module PostRepr

def base post, current_user = nil
json = post.as_json(BASE)
return json unless current_user
return json.merge(viewed: false) unless current_user

viewed = current_user.viewed?(post)
json.merge(viewed:)


Loading…
Cancel
Save