Skip to content

Commit f36fcd5

Browse files
committed
- Make LoadAssemblyInPsesLoadContext an Instance method instead of static. Fixes crash on windows arm64.
1 parent a697310 commit f36fcd5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/PowerShellEditorServices/Extensions/Api/EditorExtensionServiceProvider.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,9 @@ public static object GetPsesAssemblyLoadContext()
162162
/// </summary>
163163
/// <param name="assemblyPath">The absolute path of the assembly to load.</param>
164164
/// <returns>The loaded assembly object.</returns>
165-
public static Assembly LoadAssemblyInPsesLoadContext(string assemblyPath)
165+
#pragma warning disable CA1822 // Mark members as static
166+
public Assembly LoadAssemblyInPsesLoadContext(string assemblyPath)
167+
#pragma warning restore CA1822 // Mark members as static
166168
{
167169
if (!VersionUtils.IsNetCore)
168170
{

0 commit comments

Comments
 (0)