manually add protobuf generated files

This commit is contained in:
philippe44
2023-03-27 20:16:38 -07:00
parent fc78b36c1f
commit 31184b6946
14 changed files with 1258 additions and 15 deletions

View File

@@ -130,12 +130,9 @@ void LoginBlob::loadUserPass(const std::string& username,
void LoginBlob::loadJson(const std::string& json) {
#ifdef BELL_ONLY_CJSON
cJSON* root = cJSON_Parse(json.c_str());
cJSON* item = cJSON_GetObjectItem(root, "authType");
this->authType = item->valueint;
item = cJSON_GetObjectItem(root, "username");
this->username = item->valuestring;
item = cJSON_GetObjectItem(root, "authData");
std::string authDataObject = item->valuestring;
this->authType = cJSON_GetObjectItem(root, "authType")->valueint;
this->username = cJSON_GetObjectItem(root, "username")->valuestring;
std::string authDataObject = cJSON_GetObjectItem(root, "authData")->valuestring;
cJSON_Delete(root);
#else
auto root = nlohmann::json::parse(json);