Skip to content

Commit aa8fa92

Browse files
committed
fix(utils): remove async references in sync client
1 parent 2b8b9b2 commit aa8fa92

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

utils/run-unasync.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,14 @@ def run_unasync(output_dir: Path, check: bool = False) -> None:
4848
)
4949
filepaths = collect_files(source_dir)
5050
unasync.unasync_files(filepaths, [rule])
51+
if replacements:
52+
for path in target_dir.rglob("*.py"):
53+
text = path.read_text()
54+
new_text = text
55+
for old, new in replacements.items():
56+
new_text = new_text.replace(old, new)
57+
if new_text != text:
58+
path.write_text(new_text)
5159

5260
if check:
5361
diffs: list[str] = []

0 commit comments

Comments
 (0)