This commit is contained in:
3
main.go
3
main.go
@@ -56,10 +56,13 @@ func main() {
|
||||
r.Route("/api/artists", func(r chi.Router) {
|
||||
r.Get("/", libraryController.GetArtists)
|
||||
r.Get("/{id}", libraryController.GetArtist)
|
||||
r.Get("/{id}/songs", libraryController.GetSongsByArtist)
|
||||
})
|
||||
|
||||
r.Route("/api/albums", func(r chi.Router) {
|
||||
r.Get("/", libraryController.GetAlbums)
|
||||
r.Get("/{id}", libraryController.GetAlbum)
|
||||
r.Get("/{id}/songs", libraryController.GetSongsByAlbum)
|
||||
})
|
||||
|
||||
http.ListenAndServe(":8102", r)
|
||||
|
||||
Reference in New Issue
Block a user