Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions src/routes/sessions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -590,13 +590,11 @@ export function registerSessionRoutes(app: FastifyInstance, ctx: RouteContext):
updates.isPinned = body.isPinned;
}
if (Object.keys(updates).length === 0) {
reply.code(400);
return { error: 'No valid fields to update', code: 'INVALID_UPDATE' };
return reply.status(400).send({ error: 'No valid fields to update', code: 'INVALID_UPDATE' });
}
const updated = await sessions.updateSessionMetadata(session.id, updates);
if (!updated) {
reply.code(404);
return { error: 'Session not found', code: 'NOT_FOUND' };
return reply.status(404).send({ error: 'Session not found', code: 'NOT_FOUND' });
}
return addActionHints(updated, sessions, channels);
}));
Expand Down
8 changes: 0 additions & 8 deletions src/services/acp/local-storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -944,14 +944,6 @@ function serializeStateLightweight(state: LocalState): SerializedState {
};
}

/**
* Original serializeState kept for backward compat with the legacy cloneEvent path.
* Issue #4032: Only used by the persist path which now uses serializeStateLightweight.
*/
function serializeState(state: LocalState): SerializedState {
return serializeStateLightweight(state);
}

function deserializeState(value: unknown): LocalState {
if (!isSerializedState(value)) {
throw new Error('FileAcpLocalStorageProfile: invalid storage file');
Expand Down
Loading