File tree Expand file tree Collapse file tree 3 files changed +8
-5
lines changed Expand file tree Collapse file tree 3 files changed +8
-5
lines changed Original file line number Diff line number Diff line change 3131use Psr \Container \ContainerInterface ;
3232use Psr \Http \Message \ResponseInterface ;
3333use Psr \Http \Message \ServerRequestInterface ;
34+ use Throwable ;
3435
3536class Client extends Server
3637{
@@ -204,7 +205,7 @@ protected function execute(ServerRequestInterface $psr7Request): ResponseInterfa
204205
205206 try {
206207 $ psr7Response = $ this ->dispatcher ->dispatch ($ psr7Request , $ middlewares , $ this ->coreMiddleware );
207- } catch (\ Throwable $ throwable ) {
208+ } catch (Throwable $ throwable ) {
208209 // Delegate the exception to exception handler.
209210 $ psr7Response = $ this ->exceptionHandlerDispatcher ->dispatch ($ throwable , $ this ->exceptionHandlers );
210211 }
Original file line number Diff line number Diff line change 1313
1414use Hyperf \Testing \Debug ;
1515use PHPUnit \Framework \TestCase ;
16+ use stdClass ;
1617
1718/**
1819 * @internal
@@ -22,10 +23,10 @@ class DebugTest extends TestCase
2223{
2324 public function testGetRefCount ()
2425 {
25- $ this ->assertSame ('1 ' , Debug::getRefCount (new \ stdClass ()));
26- $ obj = new \ stdClass ();
26+ $ this ->assertSame ('1 ' , Debug::getRefCount (new stdClass ()));
27+ $ obj = new stdClass ();
2728 $ this ->assertSame ('2 ' , Debug::getRefCount ($ obj ));
28- $ obj2 = new \ stdClass ();
29+ $ obj2 = new stdClass ();
2930 $ obj2 ->obj = $ obj ;
3031 $ this ->assertSame ('2 ' , Debug::getRefCount ($ obj2 ));
3132 $ this ->assertSame ('3 ' , Debug::getRefCount ($ obj ));
Original file line number Diff line number Diff line change 1414use Hyperf \Context \Context ;
1515use Hyperf \Utils \Coroutine ;
1616use Psr \Http \Message \ServerRequestInterface ;
17+ use RuntimeException ;
1718
1819class FooController
1920{
@@ -24,7 +25,7 @@ public function index()
2425
2526 public function exception ()
2627 {
27- throw new \ RuntimeException ('Server Error ' , 500 );
28+ throw new RuntimeException ('Server Error ' , 500 );
2829 }
2930
3031 public function id ()
You can’t perform that action at this time.
0 commit comments