fix(core): return type annotation for maybe_with_colon() [no changelog]
What changed, and why it matters
This is a one-line change adding a missing Python type-hint return annotation to a helper function. It does not alter any runtime behavior, data flow, or security boundary.
No security action required. Treat as a normal code-quality/type-annotation fix.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The commit adds -> Iterable[StrPropertyType] | str | None to maybe_with_colon() in core/src/trezor/ui/layouts/properties.py. The function body is unchanged. This is purely a static-typing/documentation fix with no executable code difference.
Changed components
core/src/trezor/ui/layouts/properties.pyInspect captured patch +1 / −1
diff --git a/core/src/trezor/ui/layouts/properties.py b/core/src/trezor/ui/layouts/properties.py
index 16f0157e..e55bd25d 100644
--- a/core/src/trezor/ui/layouts/properties.py
+++ b/core/src/trezor/ui/layouts/properties.py
@@ -54,7 +54,7 @@ def with_colon(
def maybe_with_colon(
properties: Iterable[StrPropertyType] | str | None = None,
-):
+) -> Iterable[StrPropertyType] | str | None:
"""Add a colon to the end of the first element of each property tuple if the UI layout should have colons"""
if utils.UI_LAYOUT in ("BOLT", "CAESAR"):
return with_colon(properties)
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.