Skip to content

Commit 6bcdf6c

Browse files
chore(core): drop unused readExt helper and its public export
1 parent f4fd196 commit 6bcdf6c

2 files changed

Lines changed: 1 addition & 10 deletions

File tree

packages/core/src/exports/public/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ export type {
4949
RequestOptions,
5050
ServerContext
5151
} from '../../shared/protocol.js';
52-
export { DEFAULT_REQUEST_TIMEOUT_MSEC, readExt } from '../../shared/protocol.js';
52+
export { DEFAULT_REQUEST_TIMEOUT_MSEC } from '../../shared/protocol.js';
5353

5454
// Task manager types (NOT TaskManager class itself — internal)
5555
export type { RequestTaskStore, TaskContext, TaskManagerOptions, TaskRequestOptions } from '../../shared/taskManager.js';

packages/core/src/shared/context.ts

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -196,15 +196,6 @@ export type BaseContext = {
196196
ext?: Record<string, unknown>;
197197
};
198198

199-
/**
200-
* Typed reader for an extension key on {@linkcode BaseContext.ext}. Extensions export
201-
* a thin wrapper around this (e.g. `taskContext(ctx)`) so handlers get a typed value
202-
* without casting at the call site.
203-
*/
204-
export function readExt<T>(ctx: BaseContext, key: string): T | undefined {
205-
return ctx.ext?.[key] as T | undefined;
206-
}
207-
208199
/**
209200
* Context provided to server-side request handlers, extending {@linkcode BaseContext} with server-specific fields.
210201
*/

0 commit comments

Comments
 (0)