From 6d3ca3d5310cff3ce07d979bc2cce679a2654e8d Mon Sep 17 00:00:00 2001 From: moneroexamples Date: Sat, 20 Aug 2016 18:43:30 +0800 Subject: [PATCH] tmp show headers --- main.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/main.cpp b/main.cpp index d5503f4..7d8f8ab 100644 --- a/main.cpp +++ b/main.cpp @@ -139,9 +139,6 @@ int main(int ac, const char* av[]) { CROW_ROUTE(app, "/block/") ([&](const crow::request& req, string block_hash) { - for (const auto& m : req.headers) - cout << m.first << ": " << m.second << endl; - // there is some robot scanning everything // on the explorer. I block it with this if (!xmreg::does_header_has(req, "Accept", "q=.2, */*; q=.2").empty()) @@ -156,6 +153,10 @@ int main(int ac, const char* av[]) { CROW_ROUTE(app, "/tx/") ([&](const crow::request& req, string tx_hash) { + + for (const auto& m : req.headers) + cout << m.first << ": " << m.second << endl; + // there is some robot scanning everything // on the explorer. I block it with this if (!xmreg::does_header_has(req, "Accept", "q=.2, */*; q=.2").empty())