Fixed potential bug in last commit

If an object key at the root of the JSON tree has the same name than the nested object key.