Files
netbox/netbox
Mark Coleman 95caffb164
Some checks failed
CI / build (20.x, 3.12) (push) Has been cancelled
CI / build (20.x, 3.13) (push) Has been cancelled
CI / build (20.x, 3.14) (push) Has been cancelled
Refactor: centralize module token substitution logic
Per sigprof's review feedback, extract the duplicated token substitution
logic into a single resolve_module_token() helper in constants.py.

This addresses two review comments:
1. Duplication between ModuleCommonForm.clean() and resolve_name()
2. Duplication between resolve_name() and resolve_label()

Benefits:
- Single source of truth for substitution logic
- MODULE_TOKEN_SEPARATOR constant for future configurability
- Cleaner, more maintainable code (-7 net lines)
- Easier to modify separator handling in one place
2026-01-19 16:14:20 +01:00
..
2025-12-16 13:48:45 -05:00
2025-12-09 10:39:48 -08:00
2025-12-09 10:39:48 -08:00
2025-12-16 13:48:45 -05:00
2025-12-09 10:39:48 -08:00
2025-12-16 13:48:45 -05:00