Adding more logs (#6)
Reviewed-on: https://gitea.com/gitea/gitea-mcp/pulls/6 Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: hiifong <i@hiif.ong> Co-committed-by: hiifong <i@hiif.ong>
This commit is contained in:
1 parent
97b98c3fc2
commit
5270d2eb08
9 files changed
+87
-82
No files matched your search
@@ -21,3 +21,8 @@ func TextResult(v any) (*mcp.CallToolResult, error) {
|
||||
log.Debugf("Text Result: %s", string(resultBytes))
|
||||
return mcp.NewToolResultText(string(resultBytes)), nil
|
||||
}
|
||||
|
||||
func ErrorResult(err error) (*mcp.CallToolResult, error) {
|
||||
log.Errorf(err.Error())
|
||||
return nil, err
|
||||
}
|
||||
Reference in new issue
Block a user