6 lines
189 B
Ruby
6 lines
189 B
Ruby
json.extract! @player, :id, :game_id, :user_id, :created_at, :updated_at
|
|
if @player.user == current_user
|
|
json.inventory @player.inventory
|
|
end
|
|
json.inventory_count @player.inventory.count
|