fix: use _meta instead of meta in newSession request (#8796)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -190,9 +190,7 @@ export async function newSession(
|
||||
): Promise<NewSessionResponse> {
|
||||
const tClient = performance.now();
|
||||
const client = await getClient();
|
||||
const request: Parameters<typeof client.newSession>[0] & {
|
||||
meta?: Record<string, string>;
|
||||
} = {
|
||||
const request: Parameters<typeof client.newSession>[0] = {
|
||||
cwd: workingDir,
|
||||
mcpServers: [],
|
||||
};
|
||||
@@ -201,7 +199,7 @@ export async function newSession(
|
||||
if (providerId) meta.provider = providerId;
|
||||
if (projectId) meta.projectId = projectId;
|
||||
if (personaId) meta.personaId = personaId;
|
||||
if (Object.keys(meta).length > 0) request.meta = meta;
|
||||
if (Object.keys(meta).length > 0) request._meta = meta;
|
||||
|
||||
const tCall = performance.now();
|
||||
const response = await client.newSession(request);
|
||||
|
||||
Reference in New Issue
Block a user