mirror of
https://github.com/openclaw/openclaw.git
synced 2026-03-30 09:50:39 +00:00
fix: remove duplicate comment in orderProfilesByMode (#21409)
Merged via /review-pr -> /prepare-pr -> /merge-pr.
Prepared head SHA: 04271651d4
Co-authored-by: adhitShet <131381638+adhitShet@users.noreply.github.com>
Co-authored-by: gumadeiras <5599352+gumadeiras@users.noreply.github.com>
Reviewed-by: @gumadeiras
This commit is contained in:
@@ -144,8 +144,7 @@ function orderProfilesByMode(order: string[], store: AuthProfileStore): string[]
|
||||
}
|
||||
}
|
||||
|
||||
// Sort available profiles by lastUsed (oldest first = round-robin)
|
||||
// Then by lastUsed (oldest first = round-robin within type)
|
||||
// Sort available profiles by type preference, then by lastUsed (oldest first = round-robin within type)
|
||||
const scored = available.map((profileId) => {
|
||||
const type = store.profiles[profileId]?.type;
|
||||
const typeScore = type === "oauth" ? 0 : type === "token" ? 1 : type === "api_key" ? 2 : 3;
|
||||
|
||||
Reference in New Issue
Block a user