#8936 - fix bug when pid of object fetched was integer(PIC typed) instead of string

This commit is contained in:
Bernaldo Mihasi 2023-07-27 10:06:04 +03:00
parent a737fec19d
commit e01709f886
1 changed files with 7 additions and 1 deletions

View File

@ -70,7 +70,13 @@ public class RemoteFetcherUtils {
Object pidObj = stringObjectMap.get(value.split("\\.")[0]);
if(pidObj != null){
if(pidObj instanceof Map){
pid = ((Map<String, String>) pidObj).get(value.split("\\.")[1]);
Object o = ((Map<String, Object>) pidObj).get(value.split("\\.")[1]);
if(o instanceof String){
pid = (String)o;
}
else if(o instanceof Integer){
pid = String.valueOf(o);
}
}
else if(pidObj instanceof List){
Object o = ((List<Map<String,?>>) pidObj).get(0).get(value.split("\\.")[1]);