Skip to content

Commit

Permalink
register the funcmap
Browse files Browse the repository at this point in the history
  • Loading branch information
jryannel committed Aug 23, 2024
1 parent 81df201 commit 781338f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 1 addition & 3 deletions pkg/gen/filters/filterjava/filters.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ package filterjava

import "text/template"

func PopulateFuncMap() template.FuncMap {
fm := make(template.FuncMap)
func PopulateFuncMap(fm template.FuncMap) {
fm["javaDefault"] = javaDefault
fm["javaReturn"] = javaReturn
fm["javaParam"] = javaParam
Expand All @@ -12,5 +11,4 @@ func PopulateFuncMap() template.FuncMap {
fm["javaVars"] = javaVars
fm["javaType"] = javaType
fm["javaExtern"] = javaExtern
return fm
}
2 changes: 2 additions & 0 deletions pkg/gen/filters/funcmap.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
"github.com/apigear-io/cli/pkg/gen/filters/common"
"github.com/apigear-io/cli/pkg/gen/filters/filtercpp"
"github.com/apigear-io/cli/pkg/gen/filters/filtergo"
"github.com/apigear-io/cli/pkg/gen/filters/filterjava"
"github.com/apigear-io/cli/pkg/gen/filters/filterjs"
"github.com/apigear-io/cli/pkg/gen/filters/filterpy"
"github.com/apigear-io/cli/pkg/gen/filters/filterqt"
Expand All @@ -26,6 +27,7 @@ func PopulateFuncMap() template.FuncMap {
filterqt.PopulateFuncMap(fm)
filterjs.PopulateFuncMap(fm)
filterrs.PopulateFuncMap(fm)
filterjava.PopulateFuncMap(fm)

return fm
}

0 comments on commit 781338f

Please sign in to comment.