| 88 | Do_ua_req_url_host::Do_ua_req_url_host(Expr &&expr) : _expr(std::move(expr)) {} |
| 89 | |
| 90 | Errata |
| 91 | Do_ua_req_url_host::invoke(Context &ctx) |
| 92 | { |
| 93 | if (auto hdr{ctx.ua_req_hdr()}; hdr.is_valid()) { |
| 94 | if (auto url{hdr.url()}; url.is_valid()) { |
| 95 | auto value = ctx.extract(_expr); |
| 96 | if (auto host = std::get_if<IndexFor(STRING)>(&value); nullptr != host) { |
| 97 | url.host_set(*host); |
| 98 | } |
| 99 | } |
| 100 | } |
| 101 | return {}; |
| 102 | } |
| 103 | |
| 104 | swoc::Rv<Directive::Handle> |
| 105 | Do_ua_req_url_host::load(Config &cfg, CfgStaticData const *, YAML::Node drtv_node, swoc::TextView const &, swoc::TextView const &, |
nothing calls this directly
no test coverage detected