def METHOD_NAME(apps, schema_editor):
    """Fix `group_keys` structure for `group-config`"""
    GroupConfig = apps.get_model("cm", "GroupConfig")
    ConfigLog = apps.get_model("cm", "ConfigLog")
    for group in GroupConfig.objects.all():
        if group.config is not None:
            spec = get_config_spec(apps, group)
            _, custom_group_keys = create_group_keys(spec)
            current_config_log = ConfigLog.objects.get(id=group.config.current)
            group_keys = current_config_log.attr["group_keys"]
            correct_group_keys = fix_group_keys(group_keys, spec)
            current_config_log.attr["group_keys"] = correct_group_keys
            current_config_log.attr["custom_group_keys"] = custom_group_keys
            current_config_log.save()