mcp/client: fix typo in changeAndNotify&ReadResource (#68)
This PR updates the comments for func changeAndNotify and ReadResource to correct typos and improve clarity.
This commit is contained in:
parent
8a3f272dbb
commit
45f700ea13
1 changed files with 2 additions and 2 deletions
|
|
@ -191,7 +191,7 @@ func (c *Client) RemoveRoots(uris ...string) {
|
|||
func() bool { return c.roots.remove(uris...) })
|
||||
}
|
||||
|
||||
// changeAndNotifyClient is called when a feature is added or removed.
|
||||
// changeAndNotify is called when a feature is added or removed.
|
||||
// It calls change, which should do the work and report whether a change actually occurred.
|
||||
// If there was a change, it notifies a snapshot of the sessions.
|
||||
func (c *Client) changeAndNotify(notification string, params Params, change func() bool) {
|
||||
|
|
@ -347,7 +347,7 @@ func (cs *ClientSession) ListResourceTemplates(ctx context.Context, params *List
|
|||
return handleSend[*ListResourceTemplatesResult](ctx, cs, methodListResourceTemplates, orZero[Params](params))
|
||||
}
|
||||
|
||||
// ReadResource ask the server to read a resource and return its contents.
|
||||
// ReadResource asks the server to read a resource and return its contents.
|
||||
func (cs *ClientSession) ReadResource(ctx context.Context, params *ReadResourceParams) (*ReadResourceResult, error) {
|
||||
return handleSend[*ReadResourceResult](ctx, cs, methodReadResource, orZero[Params](params))
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue