Commit 67c6f61
Fix empty display_name for Lichess autocomplete results
_slim_profile's "username" field falls back to data.get("id") since
autocomplete's raw JSON only has "id", not "username" — but "display_name"
never had the same fallback, so it was always "" for every autocomplete
candidate. That made the resolver's cheap name-only first pass
(_resolve_lichess_by_autocomplete, which ranks all candidates before
fetching full profiles for just the top 2) score every candidate against
_name_score(name, ""), i.e. effectively unranked/random order rather than
name-similarity-driven.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>1 parent d6f7dec commit 67c6f61
2 files changed
Lines changed: 15 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
166 | | - | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
167 | 173 | | |
168 | 174 | | |
169 | 175 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
103 | 103 | | |
104 | 104 | | |
105 | 105 | | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
106 | 114 | | |
107 | 115 | | |
108 | 116 | | |
| |||
0 commit comments