fix(ex05): use uppercase level specifiers

This commit is contained in:
Khaïs COLIN 2025-05-13 09:54:00 +02:00
parent fd476b2c63
commit 3fa6069da8
Signed by: logistic-bot
SSH key fingerprint: SHA256:RlpiqKeXpcPFZZ4y9Ou4xi2M8OhRJovIwDlbCaMsuAo
2 changed files with 8 additions and 8 deletions

View file

@ -5,10 +5,10 @@ typedef void (Harl::*HarlComplaint)(void);
int getLevelIdx(std::string level) {
static const std::string levels[] = {
"debug",
"info",
"warning",
"error",
"DEBUG",
"INFO",
"WARNING",
"ERROR",
};
for (int i = 0; i < 4; i++) {
if (level == levels[i])

View file

@ -4,9 +4,9 @@ int main(void) {
Harl harl;
harl.complain("Debug");
harl.complain("debug");
harl.complain("info");
harl.complain("warning");
harl.complain("error");
harl.complain("DEBUG");
harl.complain("INFO");
harl.complain("WARNING");
harl.complain("ERROR");
return 0;
}