mirror of
https://github.com/eitchtee/WYGIWYH.git
synced 2026-01-11 20:00:26 +01:00
[PR #428] [MERGED] fix: handle null category in TransactionCategoryField serialization #422
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/eitchtee/WYGIWYH/pull/428
Author: @SerafimPikalov
Created: 12/7/2025
Status: ✅ Merged
Merged: 12/7/2025
Merged by: @eitchtee
Base:
main← Head:fix/null-category-serialization📝 Commits (1)
fb1b383fix: handle null category in TransactionCategoryField serialization📊 Changes
1 file changed (+6 additions, -2 deletions)
View changed files
📝
app/apps/api/fields/transactions.py(+6 -2)📄 Description
Fix AttributeError when serializing transactions with null categories. The to_representation method now checks for None before accessing category properties, returning None instead of crashing.
Fixes issue where API returns 500 error when retrieving transactions without assigned categories.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.