Add Player.currentAvatar DTO field, deprecate AvatarAssignment.selected#280
Conversation
…ected Mirror the faf-java-api change that tracks the selected avatar via the login.avatar_id column exposed as the player.currentAvatar relationship. The AvatarAssignment.selected flag is now deprecated for removal. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Caution Review failedPull request was closed or merged during review No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthrough
ChangesAvatar relationship contract update
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Mirrors the faf-java-api change (FAForever/faf-java-api#1146) that makes the API the single writer of a player's selected avatar via the
login.avatar_idcolumn, exposed as theplayer.currentAvatarrelationship.Player— adds thecurrentAvatarrelationship (@Relationship("currentAvatar"), typeAvatar). Not@JsonIgnore'd so clients can PATCH it to change the selected avatar.AvatarAssignment— marksselectedas@Deprecated(forRemoval = true); the selected avatar is now tracked viaPlayer.getCurrentAvatar().Context
Part of migrating FAF's "currently selected avatar" off the legacy
avatars.selectedjoin-table flag to thelogin.avatar_idFK, with the lobby reacting via RabbitMQ. The downlords-faf-client migration to PATCHcurrentAvatar(instead of the lobby socket command) depends on this commons release.🤖 Generated with Claude Code
Summary by CodeRabbit