From 677f36cc2f94dd863ea8abafc1980d9c81cd949d Mon Sep 17 00:00:00 2001 From: Dag Brattli Date: Thu, 6 Aug 2026 07:28:20 +0200 Subject: [PATCH] docs: fix the three XML comment warnings in Core.fs `validateJson` documented only `f`, but HttpHandler expands to HttpFunc -> HttpContext -> HttpFuncResult, so F# sees three curried parameters and warns about the two undocumented ones. Its sibling `bindJson` already carries the empty `next`/`ctx` entries; this matches it. `json` had the opposite problem: it documented a `ctx` parameter it does not have. The `let bytes` hoist means the lambda is a returned value rather than further curried parameters, so only `dataObj` is a parameter. Same shape as `text` and `htmlFile`, neither of which documents `ctx`. Each warning was reported once per backend project, hence nine lines in the release build. All three projects now build with 0 warnings. Co-Authored-By: Claude Opus 5 (1M context) --- src/Core.fs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Core.fs b/src/Core.fs index 377154d..7c21363 100644 --- a/src/Core.fs +++ b/src/Core.fs @@ -242,6 +242,8 @@ module Core = /// Additive rather than a change to bindJson: apps opt in where they want it. /// /// A function which accepts an object of type 'T and returns a function. + /// + /// /// /// A Giraffe function which can be composed into a bigger web application. let inline validateJson<'T> (f: 'T -> HttpHandler) : HttpHandler = @@ -319,7 +321,6 @@ module Core = /// It also sets the HTTP Content-Type header to application/json and sets the Content-Length header accordingly. /// /// The object to be send back to the client. - /// /// /// A Giraffe function which can be composed into a bigger web application. ///