Skip to content

Commit 0ae97fb

Browse files
committed
Simplify code
1 parent 6fbd424 commit 0ae97fb

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

server/routes.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ const (
2020

2121
// Routes defines a map between the routes and the routes' argument
2222
var Routes = map[Route]RouterArguments{
23-
CreateJob: RouterArguments{Path: "/jobs", Method: http.MethodPost},
24-
StartJob: RouterArguments{Path: "/jobs/{jobID}/start", Method: http.MethodPost},
25-
ListJobs: RouterArguments{Path: "/jobs", Method: http.MethodGet},
26-
GetJobDetails: RouterArguments{Path: "/jobs/{jobID}", Method: http.MethodGet},
27-
DeleteJob: RouterArguments{Path: "/jobs/{jobID}", Method: http.MethodDelete},
23+
CreateJob: {Path: "/jobs", Method: http.MethodPost},
24+
StartJob: {Path: "/jobs/{jobID}/start", Method: http.MethodPost},
25+
ListJobs: {Path: "/jobs", Method: http.MethodGet},
26+
GetJobDetails: {Path: "/jobs/{jobID}", Method: http.MethodGet},
27+
DeleteJob: {Path: "/jobs/{jobID}", Method: http.MethodDelete},
2828
}

0 commit comments

Comments
 (0)