Refactor sync_from_state method in Room model; update parameter types for section_map and function_map to improve clarity and consistency
This commit is contained in:
parent
543494120c
commit
eddaa69158
5 changed files with 46 additions and 47 deletions
|
@ -50,9 +50,10 @@ class Area(db.Model):
|
|||
|
||||
# Record real (non-temp) IDs
|
||||
try:
|
||||
parsed_id = int(raw_id)
|
||||
if parsed_id >= 0:
|
||||
seen_ids.add(parsed_id)
|
||||
if raw_id is not None:
|
||||
parsed_id = int(raw_id)
|
||||
if parsed_id >= 0:
|
||||
seen_ids.add(parsed_id)
|
||||
except (ValueError, TypeError):
|
||||
pass
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue