mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-06-04 08:04:48 -07:00
chore: address PR feedback by adding inline comments
This commit is contained in:
@@ -2832,7 +2832,11 @@ export class Config implements McpContext, AgentLoopContext {
|
||||
}
|
||||
|
||||
async createToolRegistry(): Promise<ToolRegistry> {
|
||||
const registry = new ToolRegistry(this, this.messageBus, true);
|
||||
const registry = new ToolRegistry(
|
||||
this,
|
||||
this.messageBus,
|
||||
/* isMainRegistry= */ true,
|
||||
);
|
||||
|
||||
// helper to create & register core tools that are enabled
|
||||
const maybeRegister = (
|
||||
|
||||
@@ -381,6 +381,8 @@ export abstract class DeclarativeTool<
|
||||
) {}
|
||||
|
||||
clone(messageBus?: MessageBus): this {
|
||||
// Note: we cannot use structuredClone() here because it does not preserve
|
||||
// prototype chains or handle non-serializable properties (like functions).
|
||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion
|
||||
const cloned = Object.assign(
|
||||
Object.create(Object.getPrototypeOf(this)),
|
||||
|
||||
Reference in New Issue
Block a user