From a78ee6af9712edf655129b5f3e960e269e952d9b Mon Sep 17 00:00:00 2001 From: Florian Hoss Date: Fri, 29 Jul 2022 17:42:08 +0200 Subject: [PATCH] Change api base and spelling --- src/API.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/API.cpp b/src/API.cpp index f436716..cabc41d 100644 --- a/src/API.cpp +++ b/src/API.cpp @@ -42,7 +42,11 @@ namespace fw String API::get_url_base() { +#ifdef ESP8266 return "https://" + this->api_ip + ":" + this->api_port; +#else + return "http://" + this->api_ip + ":" + this->api_port; +#endif } ok_t API::setup_auth(const char *username, const char *password) @@ -68,7 +72,7 @@ namespace fw { return AUTHENTICATED; } - this->json_message_response("unauthorised", 403); + this->json_message_response("unauthorized", 403); return DENIED; }