File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed
Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change 11# AsBuiltReport Default Document Style
22try {
33 # Try to initialize localized data for style elements
4+ # Use the report language from parent scope if available, otherwise fallback to OS language
45 if ($PSScriptRoot ) {
5- Initialize-LocalizedData - ModuleBasePath $PSScriptRoot - LanguageFile ' AsBuiltReportCoreStyle' - ModuleType ' Core'
6+ if ($FinalReportLanguage ) {
7+ Initialize-LocalizedData - ModuleBasePath $PSScriptRoot - LanguageFile ' AsBuiltReportCoreStyle' - ModuleType ' Core' - Language $FinalReportLanguage
8+ } else {
9+ Initialize-LocalizedData - ModuleBasePath $PSScriptRoot - LanguageFile ' AsBuiltReportCoreStyle' - ModuleType ' Core'
10+ }
611 } else {
712 # Fallback if $PSScriptRoot is not available
813 $StyleModulePath = Split-Path - Path $MyInvocation.MyCommand.Path - Parent
9- Initialize-LocalizedData - ModuleBasePath $StyleModulePath - LanguageFile ' AsBuiltReportCoreStyle' - ModuleType ' Core'
14+ if ($FinalReportLanguage ) {
15+ Initialize-LocalizedData - ModuleBasePath $StyleModulePath - LanguageFile ' AsBuiltReportCoreStyle' - ModuleType ' Core' - Language $FinalReportLanguage
16+ } else {
17+ Initialize-LocalizedData - ModuleBasePath $StyleModulePath - LanguageFile ' AsBuiltReportCoreStyle' - ModuleType ' Core'
18+ }
1019 }
1120} catch {
1221 # If localization fails, continue with default style (don't break report generation)
You can’t perform that action at this time.
0 commit comments