Skip to content

Commit edf3011

Browse files
authored
rename hasOrchestrationContext to hasInitializedDurableFunction
1 parent d9b3baf commit edf3011

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/DurableSDK/PowerShellServices.cs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ internal class PowerShellServices : IPowerShellServices
2020
private const string InternalDurableSDKName = "Microsoft.Azure.Functions.PowerShellWorker";
2121

2222
private readonly PowerShell _pwsh;
23-
private bool _hasSetOrchestrationContext = false;
23+
private bool _hasInitializedDurableFunction = false;
2424
private readonly bool _useExternalDurableSDK = false;
2525

2626
public PowerShellServices(PowerShell pwsh)
@@ -81,8 +81,7 @@ public void SetDurableClient(object durableClient)
8181
_pwsh.AddCommand(SetFunctionInvocationContextCommand)
8282
.AddParameter("DurableClient", durableClient)
8383
.InvokeAndClearCommands();
84-
// TODO: is _hasSetOrchestrationContext properly named?
85-
_hasSetOrchestrationContext = true;
84+
_hasInitializedDurableFunction = true;
8685
}
8786

8887
public OrchestrationBindingInfo SetOrchestrationContext(
@@ -117,7 +116,7 @@ public OrchestrationBindingInfo SetOrchestrationContext(
117116
.AddParameter("OrchestrationContext", orchestrationBindingInfo.Context)
118117
.InvokeAndClearCommands();
119118
}
120-
_hasSetOrchestrationContext = true;
119+
_hasInitializedDurableFunction = true;
121120
return orchestrationBindingInfo;
122121
}
123122

@@ -129,7 +128,7 @@ public void AddParameter(string name, object value)
129128

130129
public void ClearOrchestrationContext()
131130
{
132-
if (_hasSetOrchestrationContext)
131+
if (_hasInitializedDurableFunction)
133132
{
134133
_pwsh.AddCommand(SetFunctionInvocationContextCommand)
135134
.AddParameter("Clear", true)

0 commit comments

Comments
 (0)