You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can this bug be reproduced with the latest release?
Option Yes
What did you do?
s.Domain(strings.Join(config.AppConfig().Server.Domains, ",")).Group()
if config.AppConfig().Server.Domains is empty, strings.Join(config.AppConfig().Server.Domains, ",") will be a empty str (""),
and in Bind logic
// Domain creates and returns a domain object for management for one or more domains.
func (s *Server) Domain(domains string) *Domain {
d := &Domain{
server: s,
domains: make(map[string]struct{}),
}
for _, v := range strings.Split(domains, ",") {
d.domains[strings.TrimSpace(v)] = struct{}{}
}
return d
}
// BindHandler binds the handler for the specified pattern.
func (d *Domain) BindHandler(pattern string, handler interface{}) {
for domain := range d.domains {
d.server.BindHandler(pattern+"@"+domain, handler)
}
}
for range domains, actually d.server.BindHandler(pattern+"@"+"", handler)
eg: default | :8008 | POST | /api/db/sql/queryStream@
What did you see happen?
What did you expect to see?
if domains is emtpy, this domain setting is not needed.
binding url is default | :8008 | POST | /api/db/sql/queryStream not queryStream@
The text was updated successfully, but these errors were encountered:
Go version
go version go1.22.6 linux/amd64
GoFrame version
v2.7.1
Can this bug be reproduced with the latest release?
Option Yes
What did you do?
s.Domain(strings.Join(config.AppConfig().Server.Domains, ",")).Group()
if config.AppConfig().Server.Domains is empty, strings.Join(config.AppConfig().Server.Domains, ",") will be a empty str (""),
and in Bind logic
for range domains, actually d.server.BindHandler(pattern+"@"+"", handler)
eg:
default | :8008 | POST | /api/db/sql/queryStream@
What did you see happen?
What did you expect to see?
if domains is emtpy, this domain setting is not needed.
binding url is
default | :8008 | POST | /api/db/sql/queryStream
not queryStream@The text was updated successfully, but these errors were encountered: