fix(authorization): 修复自动升级检查被提前返回跳过的问题

当认种用户没有授权时,不再提前返回,确保 checkAllTeamAutoUpgrade()
始终被调用,以正确检查所有市/省团队的自动升级条件。

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
hailin 2025-12-23 07:23:46 -08:00
parent 8367530ebe
commit 454b466993
1 changed files with 2 additions and 3 deletions

View File

@ -145,12 +145,11 @@ export class EventConsumerController {
UserId.create(userId, teamStats.accountSequence),
)
// 3. 处理每个授权(如果有的话)
if (authorizations.length === 0) {
this.logger.debug(`[PLANTING] User ${userId} has no authorizations`)
return
this.logger.debug(`[PLANTING] User ${userId} has no authorizations, skipping individual auth processing`)
}
// 3. 处理每个授权
for (const auth of authorizations) {
this.logger.debug(`[PLANTING] Processing authorization: ${auth.authorizationId.value}, role=${auth.roleType}, benefitActive=${auth.benefitActive}, status=${auth.status}`)