Fixing check for HTTP POST request

This commit is contained in:
santrancisco 2023-12-20 12:37:36 +11:00
parent 6830954cd3
commit 1e86fb298a
No known key found for this signature in database
GPG Key ID: DE13EC3506E37B90

View File

@ -729,8 +729,8 @@ void HTTPHandler::processQuery(
/// to some other value.
const auto & settings = context->getSettingsRef();
/// Only readonly queries are allowed for HTTP GET requests.
if (request.getMethod() == HTTPServerRequest::HTTP_GET)
/// Anything else beside HTTP POST should be readonly queries.
if (request.getMethod() != HTTPServerRequest::HTTP_POST)
{
if (settings.readonly == 0)
context->setSetting("readonly", 2);