From ebb37d80916a00b011d7838ca980c769f59430ca Mon Sep 17 00:00:00 2001 From: Malik Moussouni Date: Thu, 10 Apr 2025 12:18:48 +0200 Subject: [PATCH] =?UTF-8?q?=E3=80=8C=F0=9F=8F=97=EF=B8=8F=E3=80=8D=20wip(h?= =?UTF-8?q?ttp):=20work=20in=20progress,=20not=20done=20yet.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Makefile | 5 +++-- src/main.cpp | 14 +++++++++++--- src/requests_handling/HttpRequests.cpp | 6 ++++-- 3 files changed, 18 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index dceb576..eb79aeb 100644 --- a/Makefile +++ b/Makefile @@ -6,7 +6,7 @@ # By: adjoly +#+ +:+ +#+ # # +#+#+#+#+#+ +#+ # # Created: 2024/10/25 16:09:27 by adjoly #+# #+# # -# Updated: 2025/02/03 16:43:32 by mmoussou ### ########.fr # +# Updated: 2025/04/10 11:52:13 by mmoussou ### ########.fr # # # # **************************************************************************** # @@ -57,6 +57,7 @@ fclean: clean @rm -Rf $(OBJSDIR) @printf "$(RED)「🗑️」 fclean($(NAME)): program deleted\n" -re: fclean all +re: fclean + @$(MAKE) -s all .PHONY: clean fclean all re diff --git a/src/main.cpp b/src/main.cpp index c4fb958..b8a6ace 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -6,7 +6,7 @@ /* By: mmoussou _body, this->getHeaders()["Content-Type"].substr(this->getHeaders()["Content-Type"].find("=", this->getHeaders()["Content-Type"].find(";")) + 1)); response.setProtocol(this->_protocol); - response.setStatusCode(204); + response.setStatusCode(200); + response.addHeader("Content-Type", "text/html"); + response.setBody(http::Errors::getResponseBody(response.getStatusCode())); } catch (...) {