| @@ -45,9 +45,9 @@ discard block | ||
| 45 | 45 | * @throws InvalidParamsException | 
| 46 | 46 | * @throws ServiceNotFoundException | 
| 47 | 47 | */ | 
| 48 | - public function __call(string $name, array $params): null|Collection|MessageInterface|Rocket | |
| 48 | + public function __call(string $name, array $params): null | Collection | MessageInterface | Rocket | |
| 49 | 49 |      { | 
| 50 | - $plugin = '\Yansongda\Pay\Shortcut\Jsb\\'.Str::studly($name).'Shortcut'; | |
| 50 | + $plugin = '\Yansongda\Pay\Shortcut\Jsb\\' . Str::studly($name) . 'Shortcut'; | |
| 51 | 51 | |
| 52 | 52 | return Artful::shortcut($plugin, ...$params); | 
| 53 | 53 | } | 
| @@ -56,7 +56,7 @@ discard block | ||
| 56 | 56 | * @throws ContainerException | 
| 57 | 57 | * @throws InvalidParamsException | 
| 58 | 58 | */ | 
| 59 | - public function pay(array $plugins, array $params): null|Collection|MessageInterface|Rocket | |
| 59 | + public function pay(array $plugins, array $params): null | Collection | MessageInterface | Rocket | |
| 60 | 60 |      { | 
| 61 | 61 | return Artful::artful($plugins, $params); | 
| 62 | 62 | } | 
| @@ -73,7 +73,7 @@ discard block | ||
| 73 | 73 | /** | 
| 74 | 74 | * @throws InvalidParamsException | 
| 75 | 75 | */ | 
| 76 | - public function cancel(array $order): Collection|Rocket | |
| 76 | + public function cancel(array $order): Collection | Rocket | |
| 77 | 77 |      { | 
| 78 | 78 | throw new InvalidParamsException(Exception::PARAMS_METHOD_NOT_SUPPORTED, 'Jsb does not support cancel api'); | 
| 79 | 79 | } | 
| @@ -81,7 +81,7 @@ discard block | ||
| 81 | 81 | /** | 
| 82 | 82 | * @throws InvalidParamsException | 
| 83 | 83 | */ | 
| 84 | - public function close(array $order): Collection|Rocket | |
| 84 | + public function close(array $order): Collection | Rocket | |
| 85 | 85 |      { | 
| 86 | 86 | throw new InvalidParamsException(Exception::PARAMS_METHOD_NOT_SUPPORTED, 'Jsb does not support close api'); | 
| 87 | 87 | } | 
| @@ -91,7 +91,7 @@ discard block | ||
| 91 | 91 | * @throws InvalidParamsException | 
| 92 | 92 | * @throws ServiceNotFoundException | 
| 93 | 93 | */ | 
| 94 | - public function refund(array $order): Collection|Rocket | |
| 94 | + public function refund(array $order): Collection | Rocket | |
| 95 | 95 |      { | 
| 96 | 96 |          Event::dispatch(new MethodCalled('jsb', __METHOD__, $order, null)); | 
| 97 | 97 | |
| @@ -102,7 +102,7 @@ discard block | ||
| 102 | 102 | * @throws ContainerException | 
| 103 | 103 | * @throws InvalidParamsException | 
| 104 | 104 | */ | 
| 105 | - public function callback(null|array|ServerRequestInterface $contents = null, ?array $params = null): Collection|Rocket | |
| 105 | + public function callback(null | array | ServerRequestInterface $contents = null, ?array $params = null): Collection | Rocket | |
| 106 | 106 |      { | 
| 107 | 107 | $request = $this->getCallbackParams($contents); | 
| 108 | 108 | |
| @@ -128,7 +128,7 @@ discard block | ||
| 128 | 128 | * @throws InvalidParamsException | 
| 129 | 129 | * @throws ServiceNotFoundException | 
| 130 | 130 | */ | 
| 131 | - public function query(array $order): Collection|Rocket | |
| 131 | + public function query(array $order): Collection | Rocket | |
| 132 | 132 |      { | 
| 133 | 133 |          Event::dispatch(new MethodCalled('jsb', __METHOD__, $order, null)); | 
| 134 | 134 | |
| @@ -55,9 +55,9 @@ discard block | ||
| 55 | 55 | * @throws InvalidParamsException | 
| 56 | 56 | * @throws ServiceNotFoundException | 
| 57 | 57 | */ | 
| 58 | - public function __call(string $shortcut, array $params): null|Collection|MessageInterface|Rocket | |
| 58 | + public function __call(string $shortcut, array $params): null | Collection | MessageInterface | Rocket | |
| 59 | 59 |      { | 
| 60 | - $plugin = '\Yansongda\Pay\Shortcut\Wechat\\'.Str::studly($shortcut).'Shortcut'; | |
| 60 | + $plugin = '\Yansongda\Pay\Shortcut\Wechat\\' . Str::studly($shortcut) . 'Shortcut'; | |
| 61 | 61 | |
| 62 | 62 | return Artful::shortcut($plugin, ...$params); | 
| 63 | 63 | } | 
| @@ -66,7 +66,7 @@ discard block | ||
| 66 | 66 | * @throws ContainerException | 
| 67 | 67 | * @throws InvalidParamsException | 
| 68 | 68 | */ | 
| 69 | - public function pay(array $plugins, array $params): null|Collection|MessageInterface|Rocket | |
| 69 | + public function pay(array $plugins, array $params): null | Collection | MessageInterface | Rocket | |
| 70 | 70 |      { | 
| 71 | 71 | return Artful::artful($plugins, $params); | 
| 72 | 72 | } | 
| @@ -76,7 +76,7 @@ discard block | ||
| 76 | 76 | * @throws InvalidParamsException | 
| 77 | 77 | * @throws ServiceNotFoundException | 
| 78 | 78 | */ | 
| 79 | - public function query(array $order): Collection|Rocket | |
| 79 | + public function query(array $order): Collection | Rocket | |
| 80 | 80 |      { | 
| 81 | 81 |          Event::dispatch(new MethodCalled('wechat', __METHOD__, $order, null)); | 
| 82 | 82 | |
| @@ -88,7 +88,7 @@ discard block | ||
| 88 | 88 | * @throws InvalidParamsException | 
| 89 | 89 | * @throws ServiceNotFoundException | 
| 90 | 90 | */ | 
| 91 | - public function cancel(array $order): Collection|Rocket | |
| 91 | + public function cancel(array $order): Collection | Rocket | |
| 92 | 92 |      { | 
| 93 | 93 |          Event::dispatch(new MethodCalled('wechat', __METHOD__, $order, null)); | 
| 94 | 94 | |
| @@ -100,7 +100,7 @@ discard block | ||
| 100 | 100 | * @throws InvalidParamsException | 
| 101 | 101 | * @throws ServiceNotFoundException | 
| 102 | 102 | */ | 
| 103 | - public function close(array $order): Collection|Rocket | |
| 103 | + public function close(array $order): Collection | Rocket | |
| 104 | 104 |      { | 
| 105 | 105 |          Event::dispatch(new MethodCalled('wechat', __METHOD__, $order, null)); | 
| 106 | 106 | |
| @@ -114,7 +114,7 @@ discard block | ||
| 114 | 114 | * @throws InvalidParamsException | 
| 115 | 115 | * @throws ServiceNotFoundException | 
| 116 | 116 | */ | 
| 117 | - public function refund(array $order): Collection|Rocket | |
| 117 | + public function refund(array $order): Collection | Rocket | |
| 118 | 118 |      { | 
| 119 | 119 |          Event::dispatch(new MethodCalled('wechat', __METHOD__, $order, null)); | 
| 120 | 120 | |
| @@ -125,7 +125,7 @@ discard block | ||
| 125 | 125 | * @throws ContainerException | 
| 126 | 126 | * @throws InvalidParamsException | 
| 127 | 127 | */ | 
| 128 | - public function callback(null|array|ServerRequestInterface $contents = null, ?array $params = null): Collection|Rocket | |
| 128 | + public function callback(null | array | ServerRequestInterface $contents = null, ?array $params = null): Collection | Rocket | |
| 129 | 129 |      { | 
| 130 | 130 | $request = $this->getCallbackParams($contents); | 
| 131 | 131 | |
| @@ -155,7 +155,7 @@ discard block | ||
| 155 | 155 | ); | 
| 156 | 156 | } | 
| 157 | 157 | |
| 158 | - protected function getCallbackParams(null|array|ServerRequestInterface $contents = null): ServerRequestInterface | |
| 158 | + protected function getCallbackParams(null | array | ServerRequestInterface $contents = null): ServerRequestInterface | |
| 159 | 159 |      { | 
| 160 | 160 |          if (is_array($contents) && isset($contents['body'], $contents['headers'])) { | 
| 161 | 161 |              return new ServerRequest('POST', 'http://localhost', $contents['headers'], $contents['body']); |