Implements proxy support for (Async)HttpClient. Ref #4423.
Fixes #2160.
This commit is contained in:
parent
0c99523ad3
commit
8386476592
3 changed files with 84 additions and 18 deletions
|
|
@ -210,6 +210,9 @@ proc `==`*(protocol: tuple[orig: string, major, minor: int],
|
|||
of HttpVer10: 0
|
||||
result = protocol.major == major and protocol.minor == minor
|
||||
|
||||
proc contains*(methods: set[HttpMethod], x: string): bool =
|
||||
return parseEnum[HttpMethod](x) in methods
|
||||
|
||||
proc `==`*(rawCode: string, code: HttpCode): bool =
|
||||
return rawCode.toLower() == ($code).toLower()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue