fix: PublicDeckOwner.pseudonym ist Bool, nicht String?
Beim Öffnen eines Marketplace-Decks crashed JSON-Decoder mit typeMismatch (Expected String, found Bool) auf owner.pseudonym. Ursache: Server-Schema (cards/apps/api/src/db/schema/marketplace/ authors.ts) hat pseudonym als `boolean NOT NULL DEFAULT false` — ein Flag, dass der Autor pseudonym auftritt (Anzeigename verbergen). Native hatte das fälschlich als String? (Anzeige-Pseudonym) interpretiert. Fix: - PublicDeckOwner.pseudonym: String? → Bool - decoder.decodeIfPresent(String.self) → decode(Bool.self) ?? false - Test-Fixture: "pseudonym": null → "pseudonym": false Build 3 → 4. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
b5edf5cf2e
commit
f528ea448a
3 changed files with 10 additions and 6 deletions
|
|
@ -31,7 +31,7 @@ struct MarketplaceDecodingTests {
|
|||
"display_name": "mana-Kuratoren",
|
||||
"verified_mana": true,
|
||||
"verified_community": false,
|
||||
"pseudonym": null
|
||||
"pseudonym": false
|
||||
}
|
||||
}
|
||||
""".data(using: .utf8)!
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue