()
| 239 | this.contentLength = contentLength |
| 240 | } |
| 241 | toJSON(): unknown { |
| 242 | const toString = this.contentType.startsWith("text/") || this.contentType.endsWith("json") |
| 243 | return { |
| 244 | _id: "effect/HttpBody", |
| 245 | _tag: "Uint8Array", |
| 246 | body: toString ? new TextDecoder().decode(this.body) : `Uint8Array(${this.body.length})`, |
| 247 | contentType: this.contentType, |
| 248 | contentLength: this.contentLength |
| 249 | } |
| 250 | } |
| 251 | } |
| 252 | |
| 253 | /** |
nothing calls this directly
no outgoing calls
no test coverage detected