mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-05 14:10:24 +00:00
fix(mattermost): detect stale websocket after bot disable/enable cycle (#53604)
Merged via squash.
Prepared head SHA: 818d437a54
Co-authored-by: Qinsam <19649380+Qinsam@users.noreply.github.com>
Co-authored-by: mukhtharcm <56378562+mukhtharcm@users.noreply.github.com>
Reviewed-by: @mukhtharcm
This commit is contained in:
@@ -227,12 +227,12 @@ function copyFileIfExists(sourcePath: string, targetPath: string): void {
|
||||
|
||||
function sanitizeLiveConfig(raw: string): string {
|
||||
try {
|
||||
const parsed = JSON5.parse(raw) as {
|
||||
const parsed: {
|
||||
agents?: {
|
||||
defaults?: Record<string, unknown>;
|
||||
list?: Array<Record<string, unknown>>;
|
||||
};
|
||||
};
|
||||
} = JSON5.parse(raw);
|
||||
if (!parsed || typeof parsed !== "object") {
|
||||
return raw;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user