Skip to content

Commit

Permalink
fix: add Plugins.* to PluginDeclaration.Category()
Browse files Browse the repository at this point in the history
  • Loading branch information
Yeuoly committed Jan 24, 2025
1 parent 2f8d22f commit fc3cba5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/entities/plugin_entities/plugin_declaration.go
Original file line number Diff line number Diff line change
Expand Up @@ -183,13 +183,13 @@ type PluginDeclaration struct {
}

func (p *PluginDeclaration) Category() PluginCategory {
if p.Tool != nil {
if p.Tool != nil || len(p.Plugins.Tools) != 0 {
return PLUGIN_CATEGORY_TOOL
}
if p.Model != nil {
if p.Model != nil || len(p.Plugins.Models) != 0 {
return PLUGIN_CATEGORY_MODEL
}
if p.AgentStrategy != nil {
if p.AgentStrategy != nil || len(p.Plugins.AgentStrategies) != 0 {
return PLUGIN_CATEGORY_AGENT_STRATEGY
}
return PLUGIN_CATEGORY_EXTENSION
Expand Down

0 comments on commit fc3cba5

Please sign in to comment.