The open source coding agent.
TypeScript
fix: import issue in patch module
Aiden Cline2dcca4755d64
diff --git a/packages/opencode/src/patch/index.ts b/packages/opencode/src/patch/index.tsindex 888a4d94b89..0efeff544f6 100644--- a/packages/opencode/src/patch/index.ts+++ b/packages/opencode/src/patch/index.ts@@ -1,6 +1,7 @@import z from "zod"import * as path from "path"import * as fs from "fs/promises"+import { readFileSync } from "fs"import { Log } from "../util/log"export namespace Patch {@@ -311,7 +312,7 @@ export namespace Patch {// Read original file contentlet originalContent: stringtry {- originalContent = require("fs").readFileSync(filePath, "utf-8")+ originalContent = readFileSync(filePath, "utf-8")} catch (error) {throw new Error(`Failed to read file ${filePath}: ${error}`)}