Skip to content

Commit

Permalink
Fix build and use the correct lower case function
Browse files Browse the repository at this point in the history
  • Loading branch information
GeheimagentNr1 committed Sep 10, 2024
1 parent e04cc20 commit b379c3d
Showing 1 changed file with 3 additions and 13 deletions.
16 changes: 3 additions & 13 deletions backend/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -259,22 +259,12 @@ void SetCid(const Napi::CallbackInfo& info)
UserSession::cid = cid;
}

std::string convertToLowercase(const std::string& str)
{
std::string result = "";

for (char ch : str) {
result += std::tolower(ch);
}
return result;
}

void SetRadioEffects(const Napi::CallbackInfo& info)
{
auto radioEffects = info[0].As<Napi::String>().Utf8Value();
radioEffects = convertToLowercase(radioEffects);
auto enableInputFilters;
auto enableOutputEffects;
radioEffects = absl::AsciiStrToLower(radioEffects);
bool enableInputFilters;
bool enableOutputEffects;

if (radioEffects == "on") {
enableInputFilters = true;
Expand Down

0 comments on commit b379c3d

Please sign in to comment.