Skip to content

Commit 89f62e2

Browse files
committed
Check for transport prior to returning it
1 parent f3eb1ad commit 89f62e2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Middleware/ApplyAuthenticationMiddleware.php

+5-1
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,11 @@ protected function getTransportFrom(ServerRequestInterface $request): ?Transport
116116
}
117117

118118
if ($this->value_container->hasValue()) {
119-
return $this->value_container->getValue();
119+
$transport = $this->value_container->getValue();
120+
121+
if ($transport instanceof TransportInterface) {
122+
return $transport;
123+
}
120124
}
121125

122126
return null;

0 commit comments

Comments
 (0)