Skip to content

Commit

Permalink
Merge pull request #35 from symsimmy/fix/compatible
Browse files Browse the repository at this point in the history
fix compatible
  • Loading branch information
symsimmy committed Jun 26, 2024
2 parents 27b2ad4 + 27a5220 commit da86ae5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion registry/consul/registry.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ func (r *Registry) Watch(ctx context.Context, namespace string, kind cluster.Kin
}

func (r *Registry) getServicesName(namespace string, kind cluster.Kind, alias string) string {
if alias == "" {
if namespace == "" || alias == "" {
return fmt.Sprintf("%s%s", namespace, string(kind))
} else {
return fmt.Sprintf("%s%s.%s", namespace, string(kind), alias)
Expand Down

0 comments on commit da86ae5

Please sign in to comment.