diff --git a/mod.ts b/mod.ts index 6b77c12..867c042 100644 --- a/mod.ts +++ b/mod.ts @@ -16,4 +16,4 @@ export { BytesRange, type ComputeBoundary, } from "./ranges/bytes.ts"; -export type { Range, RangeContext, RangeRespond } from "./types.ts"; +export type { Range, RangeContext } from "./types.ts"; diff --git a/types.ts b/types.ts index 0108f4d..63ee3a7 100644 --- a/types.ts +++ b/types.ts @@ -9,12 +9,7 @@ export interface Range { readonly rangeUnit: string; /** Takes the context of a range request and handler response and return a partial response. */ - readonly respond: RangeRespond; -} - -/** Range responding API. */ -export interface RangeRespond { - (context: RangeContext): Response | Promise; + respond(context: RangeContext): Response | Promise; } /** Context of range request and response. */