Browse Source

Make RPC handler protocol agnostic (#1276)

pull/1256/head
Alexander Simmerl 7 years ago
committed by Anton Kaliaev
parent
commit
ee51ad8e29
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      rpc/lib/server/handlers.go

+ 2
- 2
rpc/lib/server/handlers.go View File

@ -746,13 +746,13 @@ func writeListOfEndpoints(w http.ResponseWriter, r *http.Request, funcMap map[st
buf.WriteString("<br>Available endpoints:<br>")
for _, name := range noArgNames {
link := fmt.Sprintf("http://%s/%s", r.Host, name)
link := fmt.Sprintf("//%s/%s", r.Host, name)
buf.WriteString(fmt.Sprintf("<a href=\"%s\">%s</a></br>", link, link))
}
buf.WriteString("<br>Endpoints that require arguments:<br>")
for _, name := range argNames {
link := fmt.Sprintf("http://%s/%s?", r.Host, name)
link := fmt.Sprintf("//%s/%s?", r.Host, name)
funcData := funcMap[name]
for i, argName := range funcData.argNames {
link += argName + "=_"


Loading…
Cancel
Save