Repository: PowerShell/PowerShell
File: src/Microsoft.PowerShell.Commands.Utility/commands/utility/FormatAndOutput/common/GetFormatDataCommand.cs (C#)

Code before:
            if (clientVersion == null && remotingClientInfo != null)
            {
                clientVersion = PSObject.Base((PSObject.Base(remotingClientInfo.ApplicationArguments["PSVersionTable"]) as PSPrimitiveDictionary)?["PSVersion"]) as Version;
            }

            // During remoting, remain compatible with v5.0- clients by default.
            // Passing a -PowerShellVersion argument allows overriding the client version.
            bool writeOldWay =
                (remotingClientInfo != null && clientVersion == null)  // To be safe: Remoting client version could unexpectedly not be determined.
                ||
                (clientVersion != null
                    &&
                    (clientVersion.Major < 5
                        ||
                    (clientVersion.Major == 5 && clientVersion.Minor < 1)));

            TypeInfoDataBase db = this.Context.FormatDBManager.Database;

            List<ViewDefinition> viewdefinitions = db.viewDefinitionsSection.viewDefinitionList;
            Dictionary<string, List<string>> typeGroupMap = GetTypeGroupMap(db.typeGroupSection.typeGroupDefinitionList);

            var typedefs = new Dictionary<ConsolidatedString, List<FormatViewDefinition>>(ConsolidatedString.EqualityComparer);

            foreach (ViewDefinition definition in viewdefinitions)
            {
                this.WriteVerbose(string.Format(CultureInfo.InvariantCulture, GetFormatDataStrings.ProcessRecord, definition.name));
                if (definition.isHelpFormatter)
                    continue;

                var consolidatedTypeName = CreateConsolidatedTypeName(definition, typeGroupMap);

                if (!ShouldGenerateView(consolidatedTypeName))
                    continue;

                PSControl control;

                if (definition.mainControl is TableControlBody tableControlBody)
                {
                    control = new TableControl(tableControlBody, definition);
                }
                else
                {
                    if (definition.mainControl is ListControlBody listControlBody)
                    {
                        control = new ListControl(listControlBody, definition);
                    }
                    else
                    {
                        if (definition.mainControl is WideControlBody wideControlBody)
                        {
                            control = new WideControl(wideControlBody, definition);

Review comment (suggestion):
Output for user to read should be using the current culture.
```suggestion
                this.WriteVerbose(string.Format(CultureInfo.CurrentCulture, GetFormatDataStrings.ProcessViewDefinition, definition.name));
```

Code after:
            if (clientVersion == null && remotingClientInfo != null)
            {
                clientVersion = PSObject.Base((PSObject.Base(remotingClientInfo.ApplicationArguments["PSVersionTable"]) as PSPrimitiveDictionary)?["PSVersion"]) as Version;
            }

            // During remoting, remain compatible with v5.0- clients by default.
            // Passing a -PowerShellVersion argument allows overriding the client version.
            bool writeOldWay =
                (remotingClientInfo != null && clientVersion == null)  // To be safe: Remoting client version could unexpectedly not be determined.
                ||
                (clientVersion != null
                    &&
                    (clientVersion.Major < 5
                        ||
                    (clientVersion.Major == 5 && clientVersion.Minor < 1)));

            TypeInfoDataBase db = this.Context.FormatDBManager.Database;

            List<ViewDefinition> viewdefinitions = db.viewDefinitionsSection.viewDefinitionList;
            Dictionary<string, List<string>> typeGroupMap = GetTypeGroupMap(db.typeGroupSection.typeGroupDefinitionList);

            var typedefs = new Dictionary<ConsolidatedString, List<FormatViewDefinition>>(ConsolidatedString.EqualityComparer);

            foreach (ViewDefinition definition in viewdefinitions)
            {
                this.WriteVerbose(string.Format(CultureInfo.CurrentCulture, GetFormatDataStrings.ProcessViewDefinition, definition.name));
                if (definition.isHelpFormatter)
                    continue;

                var consolidatedTypeName = CreateConsolidatedTypeName(definition, typeGroupMap);

                if (!ShouldGenerateView(consolidatedTypeName))
                    continue;

                PSControl control;

                if (definition.mainControl is TableControlBody tableControlBody)
                {
                    control = new TableControl(tableControlBody, definition);
                }
                else
                {
                    if (definition.mainControl is ListControlBody listControlBody)
                    {
                        control = new ListControl(listControlBody, definition);
                    }
                    else
                    {
                        if (definition.mainControl is WideControlBody wideControlBody)
                        {
                            control = new WideControl(wideControlBody, definition);