Commit fb6e38e
committed
refactor: move json import to module level in api_stream
Local `import json as _json` inside the function body was redundant —
Python caches module imports, so there is no cost to importing at the
top. Moving it to the module-level import block makes the dependency
explicit and keeps the function body focused on its logic.1 parent c84f1d9 commit fb6e38e
1 file changed
Lines changed: 2 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
777 | 778 | | |
778 | 779 | | |
779 | 780 | | |
780 | | - | |
781 | | - | |
782 | 781 | | |
783 | 782 | | |
784 | 783 | | |
785 | 784 | | |
786 | 785 | | |
787 | 786 | | |
788 | | - | |
| 787 | + | |
789 | 788 | | |
790 | 789 | | |
791 | 790 | | |
| |||
0 commit comments