The transfer-target check previously matched only against CONFIG.ROLE_TO_PING_ID, so a member with one of CONFIG.ADDITIONAL_STAFF_ROLES (a recognized staff role everywhere else in the bot, including requireStaffRole and the messages.js claimer-DM path) was rejected as a transfer target. Switch to isStaff() so the transfer-target gate matches the rest of the codebase's staff definition. Also: - Reject bots as transfer targets (guildMember.user.bot). - Reject self-transfer (transferring to interaction.user.id) — the rename + DB write would no-op but the log line claimed a transfer that didn't happen. - Resolve the target member cache-first to avoid an unnecessary REST round-trip when the GuildMembers intent has the user cached.
14 KiB
14 KiB