We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ce01397 commit 4652ef7Copy full SHA for 4652ef7
Engine/PSScriptAnalyzer.psm1
@@ -2,6 +2,11 @@
2
# Script module for module 'PSScriptAnalyzer'
3
#
4
5
+function Test-PSEditionCoreCLR
6
+{
7
+ ($PSVersionTable.Keys -contains "PSEdition") -and ($PSVersionTable.PSEdition -ne 'Desktop')
8
+}
9
+
10
# Clear PSDefaultParameterValues in the module scope and enable strict mode
11
$PSDefaultParameterValues.Clear()
12
Set-StrictMode -Version Latest
@@ -14,7 +19,7 @@ $PSModuleRoot = $PSModule.ModuleBase
14
19
$binaryModuleRoot = $PSModuleRoot
15
20
16
21
17
-if (($PSVersionTable.Keys -contains "PSEdition") -and ($PSVersionTable.PSEdition -ne 'Desktop')) {
22
+if ((Test-PSEditionCoreCLR)) {
18
23
$binaryModuleRoot = Join-Path -Path $PSModuleRoot -ChildPath 'coreclr'
24
}
25
else
0 commit comments