mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 15:54:32 +00:00
chore: Enable more lint rules, disable some that trigger a lot. Will clean up later.
This commit is contained in:
@@ -411,7 +411,7 @@ export async function autoMigrateLegacyStateDir(params: {
|
||||
} catch (err) {
|
||||
try {
|
||||
if (process.platform === "win32") {
|
||||
if (!legacyDir) throw new Error("Legacy state dir not found");
|
||||
if (!legacyDir) throw new Error("Legacy state dir not found", { cause: err });
|
||||
fs.symlinkSync(targetDir, legacyDir, "junction");
|
||||
changes.push(formatStateDirMigration(legacyDir, targetDir));
|
||||
} else {
|
||||
@@ -419,7 +419,8 @@ export async function autoMigrateLegacyStateDir(params: {
|
||||
}
|
||||
} catch (fallbackErr) {
|
||||
try {
|
||||
if (!legacyDir) throw new Error("Legacy state dir not found");
|
||||
if (!legacyDir)
|
||||
throw new Error("Legacy state dir not found", { cause: err }, { cause: fallbackErr });
|
||||
fs.renameSync(targetDir, legacyDir);
|
||||
warnings.push(
|
||||
`State dir migration rolled back (failed to link legacy path): ${String(fallbackErr)}`,
|
||||
|
||||
Reference in New Issue
Block a user