File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -100,10 +100,11 @@ public static async Task StartAsync(string serverName, string version)
100100 . Where ( t =>
101101 {
102102 bool classHasToolAttribute = t . GetCustomAttribute < McpToolAttribute > ( ) != null ;
103- bool methodHasToolAttribute = t . GetMethods ( ) . Any ( m => m . GetCustomAttribute < McpFunctionAttribute > ( ) != null ) ;
103+ bool methodHasToolAttribute = t . GetMethods ( ) . Any ( m => m . GetCustomAttribute < McpToolAttribute > ( ) != null ) ;
104+ bool methodHasFunctionAttribute = t . GetMethods ( ) . Any ( m => m . GetCustomAttribute < McpFunctionAttribute > ( ) != null ) ;
104105 bool methodHasResourceAttribute = t . GetMethods ( ) . Any ( m => m . GetCustomAttribute < McpResourceAttribute > ( ) != null ) ;
105106
106- return classHasToolAttribute || methodHasToolAttribute || methodHasResourceAttribute ;
107+ return classHasToolAttribute || methodHasToolAttribute || methodHasFunctionAttribute || methodHasResourceAttribute ;
107108 } ) ;
108109
109110 foreach ( var toolType in allTypes )
@@ -147,4 +148,4 @@ internal void Dispose()
147148 _rpc . Dispose ( ) ;
148149 }
149150 }
150- }
151+ }
You can’t perform that action at this time.
0 commit comments