Skip to content

Commit

Permalink
- Fix al commit anterior para el caso que no viene el SDT "wrapped"
Browse files Browse the repository at this point in the history
  • Loading branch information
AlejandroP committed Feb 17, 2023
1 parent 5bc2557 commit c8decdf
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions dotnet/src/dotnetframework/GxClasses/Helpers/GXRestAPIClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -258,9 +258,15 @@ public string GetJsonStr(string varName)
else if (_responseData.Count >= 1 && !_responseData.ContainsKey(varName.ToLower()))
{
#if NETCORE
sdt.FromJSonString("{" + varName + ":" + JsonSerializer.Serialize(_responseData) + "}", null);
if (sdt.FromJSonString(JsonSerializer.Serialize(_responseData).ToString(), null))
return sdt;
else
sdt.FromJSonString("{" + varName + ":" + JsonSerializer.Serialize(_responseData) + "}", null);
#else
sdt.FromJSonString("{" + varName + ":" + JSONHelper.Serialize(_responseData) + "}", null);
if (sdt.FromJSonString(JSONHelper.Serialize(_responseData).ToString(), null))
return sdt;
else
sdt.FromJSonString("{" + varName + ":" + JSONHelper.Serialize(_responseData) + "}", null);
#endif
}
return sdt;
Expand Down

0 comments on commit c8decdf

Please sign in to comment.