Skip to content

Commit

Permalink
fix panic during create integration tables when API_LISTEN doesn't …
Browse files Browse the repository at this point in the history
…contain ":" character, fix #790
  • Loading branch information
Slach committed Nov 23, 2023
1 parent b363d94 commit 45cc5d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -1496,7 +1496,7 @@ func (api *APIServer) CreateIntegrationTables() error {
defer ch.Close()
port := "80"
if strings.Contains(api.config.API.ListenAddr, ":") {
port = api.config.API.ListenAddr[strings.Index(api.config.API.ListenAddr, ":"):]
port = api.config.API.ListenAddr[strings.Index(api.config.API.ListenAddr, ":")+1:]
}
auth := ""
if api.config.API.Username != "" || api.config.API.Password != "" {
Expand Down

0 comments on commit 45cc5d8

Please sign in to comment.