Fix for Ids replacement in JSON