mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-29 08:44:59 +00:00
refactor to use io.read_text
This commit is contained in:
parent
4c220ff63f
commit
413ddb84df
1 changed files with 2 additions and 2 deletions
|
@ -53,7 +53,7 @@ class WholeFileCoder(Coder):
|
|||
full_path = (Path(self.root) / fname).absolute()
|
||||
|
||||
if mode == "diff" and full_path.exists():
|
||||
orig_lines = full_path.read_text().splitlines(keepends=True)
|
||||
orig_lines = self.io.read_text(full_path).splitlines(keepends=True)
|
||||
|
||||
show_diff = diffs.diff_partial_update(
|
||||
orig_lines,
|
||||
|
@ -109,7 +109,7 @@ class WholeFileCoder(Coder):
|
|||
full_path = (Path(self.root) / fname).absolute()
|
||||
|
||||
if mode == "diff" and full_path.exists():
|
||||
orig_lines = full_path.read_text().splitlines(keepends=True)
|
||||
orig_lines = self.io.read_text(full_path).splitlines(keepends=True)
|
||||
|
||||
show_diff = diffs.diff_partial_update(
|
||||
orig_lines,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue