MCPcopy Create free account
hub / github.com/PageLeay/celestial-runtime / method

Method method

src.ts/utils/fetch.ts:267–271  ·  view source on GitHub ↗

* The HTTP method to use when requesting the URI. If no method * has been explicitly set, then ``GET`` is used if the body is * null and ``POST`` otherwise.

()

Source from the content-addressed store, hash-verified

265 * null and ``POST`` otherwise.
266 */
267 get method(): string {
268 if (this.#method) { return this.#method; }
269 if (this.hasBody()) { return "POST"; }
270 return "GET";
271 }
272 set method(method: null | string) {
273 if (method == null) { method = ""; }
274 this.#method = String(method).toUpperCase();

Callers

nothing calls this directly

Calls 1

hasBodyMethod · 0.95

Tested by

no test coverage detected