Skip to content

Commit 6dae484

Browse files
committed
style: fix prettier formatting in example
1 parent 5a7cbb8 commit 6dae484

File tree

2 files changed

+6
-10
lines changed

2 files changed

+6
-10
lines changed

docs/server.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -209,11 +209,9 @@ When the set of available tools changes at runtime, the server should notify con
209209

210210
```ts source="../examples/server/src/serverGuide.examples.ts#sendToolListChanged_basic"
211211
// Automatic: registering a tool at runtime sends the notification
212-
server.registerTool(
213-
'new-tool',
214-
{ description: 'A dynamically added tool' },
215-
async () => ({ content: [{ type: 'text', text: 'done' }] })
216-
);
212+
server.registerTool('new-tool', { description: 'A dynamically added tool' }, async () => ({
213+
content: [{ type: 'text', text: 'done' }]
214+
}));
217215

218216
// Manual: notify clients explicitly (e.g. after removing a tool)
219217
server.sendToolListChanged();

examples/server/src/serverGuide.examples.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -151,11 +151,9 @@ function registerTool_annotations(server: McpServer) {
151151
function sendToolListChanged_basic(server: McpServer) {
152152
//#region sendToolListChanged_basic
153153
// Automatic: registering a tool at runtime sends the notification
154-
server.registerTool(
155-
'new-tool',
156-
{ description: 'A dynamically added tool' },
157-
async () => ({ content: [{ type: 'text', text: 'done' }] })
158-
);
154+
server.registerTool('new-tool', { description: 'A dynamically added tool' }, async () => ({
155+
content: [{ type: 'text', text: 'done' }]
156+
}));
159157

160158
// Manual: notify clients explicitly (e.g. after removing a tool)
161159
server.sendToolListChanged();

0 commit comments

Comments
 (0)