Rename method
This commit is contained in:
		@@ -12,13 +12,13 @@ import (
 | 
				
			|||||||
	"net/http"
 | 
						"net/http"
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func helloOld(w http.ResponseWriter, r *http.Request) {
 | 
					func handle(w http.ResponseWriter, r *http.Request) {
 | 
				
			||||||
	io.WriteString(w, hello.Hello())
 | 
						io.WriteString(w, hello.Hello())
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func main() {
 | 
					func main() {
 | 
				
			||||||
	portNumber := "9000"
 | 
						portNumber := "9000"
 | 
				
			||||||
	http.HandleFunc("/", helloOld)
 | 
						http.HandleFunc("/", handle)
 | 
				
			||||||
	fmt.Println("Server listening on port ", portNumber)
 | 
						fmt.Println("Server listening on port ", portNumber)
 | 
				
			||||||
	http.ListenAndServe(":"+portNumber, nil)
 | 
						http.ListenAndServe(":"+portNumber, nil)
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user