router img

This commit is contained in:
2023-06-07 15:36:56 +08:00
parent 0181ef270d
commit d64e6517a1

View File

@@ -89,6 +89,8 @@ func main() {
r.HandleFunc("/api/params/model", routers.ParamsModelsGet).Methods("GET") r.HandleFunc("/api/params/model", routers.ParamsModelsGet).Methods("GET")
r.HandleFunc("/api/account", routers.AccountGet).Methods("GET") r.HandleFunc("/api/account", routers.AccountGet).Methods("GET")
r.HandleFunc("/img/{id}", routers.WebpGet).Methods("GET")
log.Println("Web Server is running on http://localhost:8080") log.Println("Web Server is running on http://localhost:8080")
if err := http.ListenAndServe(":8080", r); err != nil { if err := http.ListenAndServe(":8080", r); err != nil {
log.Fatal(err) log.Fatal(err)