Skip to content

Commit cb2a5b3

Browse files
klapaudiusgithub-actions[bot]
authored andcommitted
Fix styling
1 parent 52bcbad commit cb2a5b3

File tree

2 files changed

+8
-14
lines changed

2 files changed

+8
-14
lines changed

src/Protocol/MCPProtocol.php

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ public function __construct(TransportInterface $transport)
5252
* The method starts the transport, continuously checks for incoming messages while connected,
5353
* handles each message appropriately, and disconnects when the connection ends.
5454
*
55-
* @return void
5655
* @throws Exception
5756
*/
5857
public function connect(): void
@@ -77,8 +76,7 @@ public function connect(): void
7776
/**
7877
* Sends a message using the configured transport.
7978
*
80-
* @param string|array $message The message to be sent, either as a string or an array.
81-
* @return void
79+
* @param string|array $message The message to be sent, either as a string or an array.
8280
*/
8381
public function send(string|array $message): void
8482
{
@@ -87,8 +85,6 @@ public function send(string|array $message): void
8785

8886
/**
8987
* Disconnects the current transport by closing the connection.
90-
*
91-
* @return void
9288
*/
9389
public function disconnect(): void
9490
{
@@ -98,8 +94,7 @@ public function disconnect(): void
9894
/**
9995
* Registers a request handler to manage incoming requests.
10096
*
101-
* @param RequestHandler $handler The request handler instance to be registered.
102-
* @return void
97+
* @param RequestHandler $handler The request handler instance to be registered.
10398
*/
10499
public function registerRequestHandler(RequestHandler $handler): void
105100
{
@@ -109,8 +104,7 @@ public function registerRequestHandler(RequestHandler $handler): void
109104
/**
110105
* Registers a notification handler to handle incoming notifications.
111106
*
112-
* @param NotificationHandler $handler The notification handler instance to be registered.
113-
* @return void
107+
* @param NotificationHandler $handler The notification handler instance to be registered.
114108
*/
115109
public function registerNotificationHandler(NotificationHandler $handler): void
116110
{
@@ -121,9 +115,9 @@ public function registerNotificationHandler(NotificationHandler $handler): void
121115
* Handles an incoming JSON-RPC message from a client, processes it as either a request or notification,
122116
* and manages error responses when necessary.
123117
*
124-
* @param string $clientId The unique identifier for the client sending the message
125-
* @param array $message The JSON-RPC message data to process
126-
* @return void
118+
* @param string $clientId The unique identifier for the client sending the message
119+
* @param array $message The JSON-RPC message data to process
120+
*
127121
* @throws JsonRpcErrorException
128122
*/
129123
public function handleMessage(string $clientId, array $message): void
@@ -181,7 +175,7 @@ private function handleRequestProcess(string $clientId, RequestData $requestData
181175
} catch (JsonRpcErrorException $e) {
182176
$this->pushMessage(clientId: $clientId, message: new JsonRpcErrorResource(exception: $e, id: $messageId));
183177
} catch (ToolParamsValidatorException $e) {
184-
$jsonRpcErrorException = new JsonRpcErrorException(message: $e->getMessage() . ' ' . implode(',', $e->getErrors()), code: JsonRpcErrorCode::INVALID_PARAMS);
178+
$jsonRpcErrorException = new JsonRpcErrorException(message: $e->getMessage().' '.implode(',', $e->getErrors()), code: JsonRpcErrorCode::INVALID_PARAMS);
185179
$this->pushMessage(clientId: $clientId, message: new JsonRpcErrorResource(exception: $jsonRpcErrorException, id: $messageId));
186180
} catch (Exception $e) {
187181
$jsonRpcErrorException = new JsonRpcErrorException(message: $e->getMessage(), code: JsonRpcErrorCode::INTERNAL_ERROR);

src/Resources/config/routes.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
/**
88
* Configures routes for the application.
99
*
10-
* @param RoutingConfigurator $routes The routing configurator used to define routes.
10+
* @param RoutingConfigurator $routes The routing configurator used to define routes.
1111
* @return void
1212
*/
1313
return function (RoutingConfigurator $routes) {

0 commit comments

Comments
 (0)