(
headers: { [key: string]: string } | Headers | null,
name: string,
)
| 138 | } |
| 139 | |
| 140 | export function getHeader( |
| 141 | headers: { [key: string]: string } | Headers | null, |
| 142 | name: string, |
| 143 | ): string | null { |
| 144 | if (headers === null) return null; |
| 145 | if (typeof headers.get === "function") { |
| 146 | return headers.get(name) || headers.get(name.toLowerCase()); |
| 147 | } |
| 148 | // @ts-ignore |
| 149 | return headers[name] || headers[name.toLowerCase()] || null; |
| 150 | } |
| 151 | |
| 152 | export function getParam( |
| 153 | parameters: Record<string, any>, |
nothing calls this directly
no outgoing calls
no test coverage detected