Skip to content

Commit

Permalink
Allow people to write the public functions (#381)
Browse files Browse the repository at this point in the history
  • Loading branch information
lekko-jonathan authored May 7, 2024
1 parent ef0068a commit 202565c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/sync/golang.go
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ func (g *goSyncer) FileLocationToNamespace(ctx context.Context) (*Namespace, err
case *ast.FuncDecl:
// TODO: We should support numbers (e.g. v2) but the strcase pkg has some non-ideal behavior with numbers,
// we might want to write our own librar(ies) with cross-language consistency
if regexp.MustCompile("^get[A-Z][A-Za-z]*$").MatchString(x.Name.Name) {
if regexp.MustCompile("^[gG]et[A-Z][A-Za-z]*$").MatchString(x.Name.Name) {
var commentLines []string
if x.Doc != nil {
for _, comment := range x.Doc.List {
Expand Down

0 comments on commit 202565c

Please sign in to comment.