Skip to content

Commit

Permalink
allow isAnnotation component by default
Browse files Browse the repository at this point in the history
Signed-off-by: yash sharma <[email protected]>
  • Loading branch information
Yashsharma1911 committed Nov 26, 2023
1 parent 319f170 commit 35e94df
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions models/meshmodel/core/v1alpha1/component.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,10 @@ func GetMeshModelComponents(db *database.Handler, f ComponentFilter) (c []Compon

if f.ReturnAnnotations {
finder = finder.Where("component_definition_dbs.metadata->>'isAnnotation' = true")
} else {
// Include isAnnotation component by default
// TODO: change 'isAnnotation' = true" to 'isAnnotation' = false" if isAnnotation components should not be default provided
finder = finder.Where("component_definition_dbs.metadata->>'isAnnotation' = true")
}

if f.APIVersion != "" {
Expand Down

0 comments on commit 35e94df

Please sign in to comment.