fix fetch
This commit is contained in:
@@ -2122,9 +2122,11 @@ long LoginWrenchBoardQRAccount(CVars in, CVars &out) {
|
||||
" WHERE f.uid = '%s' AND f.username = '%s' AND m.uid = '%s' ", in["family_uid"].c_str(), in["member_username"].c_str(), in["member_uid"].c_str());
|
||||
if (res != NULL && pgsql_num_rows(res) > 0) {
|
||||
map<const char*, const char*>f = pgsql_fetch_assoc(res,0);
|
||||
CVars rec;
|
||||
map_to_cvars(f, rec);
|
||||
CVars inx;
|
||||
inx["username"] = f["username"]; inx["username"].set_valid( true );
|
||||
inx["pin"] =f["pin"]; inx["pin"].set_valid( true );
|
||||
inx["username"] = rec["username"]; inx["username"].set_valid( true );
|
||||
inx["pin"] = rec["pin"]; inx["pin"].set_valid( true );
|
||||
inx["login_mode"] = LOGIN_MODE_FAMILY; inx["login_mode"].set_valid( true );
|
||||
return LoginWrenchBoardAccount(inx, out);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user