Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
roxblnfk committed Oct 23, 2023
1 parent 5f4f868 commit 870dc00
Show file tree
Hide file tree
Showing 10 changed files with 11 additions and 14 deletions.
2 changes: 1 addition & 1 deletion src/Client/WorkflowClientInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public function newUntypedRunningWorkflowStub(
): WorkflowStubInterface;

/**
* Creates new {@link ActivityCompletionClient} that can be used to complete activities
* Creates a new {@link ActivityCompletionClient} that can be used to complete activities
* asynchronously. Only relevant for activity implementations that called {@link
* ActivityContext->doNotCompleteOnReturn()}.
*
Expand Down
2 changes: 1 addition & 1 deletion src/Client/WorkflowOptions.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ public function __construct()
* @param MethodRetry|null $retry
* @param CronSchedule|null $cron
*
* @return self return new {@see self} instance with merged options
* @return self return a new {@see self} instance with merged options
*/
public function mergeWith(MethodRetry $retry = null, CronSchedule $cron = null): self
{
Expand Down
2 changes: 1 addition & 1 deletion src/Interceptor/ActivityInboundInterceptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
use Temporal\Internal\Interceptor\Interceptor;

/**
* It recommended to use {@see ActivityInboundInterceptorTrait} when implementing this interface because
* It's recommended to use {@see ActivityInboundInterceptorTrait} when implementing this interface because
* the interface might be extended in the future. The trait will provide forward compatibility.
*
* @psalm-immutable
Expand Down
2 changes: 1 addition & 1 deletion src/Interceptor/WorkflowClientCallsInterceptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
use Temporal\Workflow\WorkflowExecution;

/**
* It recommended to use {@see WorkflowClientCallsInterceptorTrait} when implementing this interface because
* It's recommended to use {@see WorkflowClientCallsInterceptorTrait} when implementing this interface because
* the interface might be extended in the future. The trait will provide forward compatibility.
*
* @psalm-immutable
Expand Down
2 changes: 1 addition & 1 deletion src/Interceptor/WorkflowInboundInterceptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
use Temporal\Internal\Interceptor\Interceptor;

/**
* It recommended to use {@see WorkflowInboundInterceptorTrait} when implementing this interface because
* It's recommended to use {@see WorkflowInboundInterceptorTrait} when implementing this interface because
* the interface might be extended in the future. The trait will provide forward compatibility.
*
* @psalm-immutable
Expand Down
2 changes: 1 addition & 1 deletion src/Interceptor/WorkflowOutboundCallsInterceptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
/**
* Interceptor for outbound workflow calls.
*
* It recommended to use {@see WorkflowOutboundCallsInterceptorTrait} when implementing this interface because
* It's recommended to use {@see WorkflowOutboundCallsInterceptorTrait} when implementing this interface because
* the interface might be extended in the future. The trait will provide forward compatibility.
*
* @psalm-immutable
Expand Down
2 changes: 1 addition & 1 deletion src/Interceptor/WorkflowOutboundRequestInterceptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
/**
* Intercept a request before it's sent to RoadRunner.
*
* It recommended to use {@see WorkflowOutboundRequestInterceptorTrait} when implementing this interface because
* It's recommended to use {@see WorkflowOutboundRequestInterceptorTrait} when implementing this interface because
* the interface might be extended in the future. The trait will provide forward compatibility.
*
* @psalm-immutable
Expand Down
7 changes: 2 additions & 5 deletions src/Internal/Workflow/Process/Scope.php
Original file line number Diff line number Diff line change
Expand Up @@ -326,11 +326,6 @@ public function onAwait(Deferred $deferred): void
$deferred->promise()->then($cleanup, $cleanup);
}

/**
* @param bool $detached
* @param string|null $layer
* @return self
*/
protected function createScope(bool $detached, string $layer = null, WorkflowContextInterface $context = null): self
{
$scope = new Scope($this->services, $context ?? $this->context);
Expand Down Expand Up @@ -421,6 +416,7 @@ protected function onRequest(RequestInterface $request, PromiseInterface $promis
$this->context->getClient()->cancel($request);
return;
}
// todo ->context or ->scopeContext?
$this->context->getClient()->request(new Cancel($request->getID()), $this->scopeContext);
};
Expand Down Expand Up @@ -470,6 +466,7 @@ protected function next(): void
$this->nextPromise($current->promise());
break;

// todo ->context or ->scopeContext?
case $current instanceof RequestInterface:
$this->nextPromise($this->context->getClient()->request($current, $this->scopeContext));
break;
Expand Down
2 changes: 1 addition & 1 deletion src/Workflow.php
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ public static function registerQuery(string $queryType, callable $handler): Scop
* The same method ({@see WorkflowStubInterface::signal()}) should be used
* to call such signal handlers as in the case of ordinary signal methods.
*
* @param string $queryType
* @param non-empty-string $queryType
* @param callable $handler
* @return ScopedContextInterface
* @throws OutOfContextException in the absence of the workflow execution context.
Expand Down
2 changes: 1 addition & 1 deletion tests/Fixtures/src/Workflow/RuntimeSignalWorkflow.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public function handler()

$counter = 0;

Workflow::registerSignal('add', function ($value) use (&$counter, $wait1, $wait2) {
Workflow::registerSignal('add', static function ($value) use (&$counter, $wait1, $wait2) {
$counter += $value;
$wait1->resolve($value);
$wait2->resolve($value);
Expand Down

0 comments on commit 870dc00

Please sign in to comment.