Change api base and spelling

This commit is contained in:
Florian Hoss 2022-07-29 17:42:08 +02:00
parent 2e4cdb3734
commit a78ee6af97

View file

@ -42,7 +42,11 @@ namespace fw
String API::get_url_base() String API::get_url_base()
{ {
#ifdef ESP8266
return "https://" + this->api_ip + ":" + this->api_port; 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) ok_t API::setup_auth(const char *username, const char *password)
@ -68,7 +72,7 @@ namespace fw
{ {
return AUTHENTICATED; return AUTHENTICATED;
} }
this->json_message_response("unauthorised", 403); this->json_message_response("unauthorized", 403);
return DENIED; return DENIED;
} }