store: Fix: Rust sync excluded IL/MiL teams due to active_only=true

This commit is contained in:
Cal Corum 2026-02-28 12:09:23 -06:00
parent cb44ab1755
commit cf544d40d0

View File

@ -0,0 +1,35 @@
---
id: 5c11485a-c808-41b6-8576-a8a388b5be1e
type: fix
title: "Fix: Rust sync excluded IL/MiL teams due to active_only=true"
tags: [sba-scout, rust, sync, bug-fix, api, teams]
importance: 0.7
confidence: 0.8
created: "2026-02-28T18:09:23.796074+00:00"
updated: "2026-02-28T18:09:23.796074+00:00"
---
# Fix: Rust sync excluded IL/MiL teams due to active_only=true
## Problem
The Rust `sync_teams()` function in `api/sync.rs` was calling:
```rust
client.get_teams(Some(season), None, true, false)
```
The `active_only=true` parameter caused the API to exclude IL (e.g. WVIL id=549) and MiL (e.g. WVMiL id=550) teams from the response. The Python sync did not pass `active_only` (defaults to `false`), so it correctly synced all teams.
## Root Cause
Mismatch between Rust and Python API call defaults for the `active_only` parameter.
## Fix
Changed `active_only` from `true` to `false` in `api/sync.rs`.
## Notes
- The `get_all_teams()` DB query in `queries.rs` already filters IL/MiL from the Gameday opponent selector using `WHERE abbrev NOT LIKE '%IL' AND abbrev NOT LIKE '%MiL'`, so syncing them does not pollute the UI.
- Committed as part of `3e73644`.