package v1 import ( "git.mowie.cc/konrad/Library/models" "github.com/labstack/echo" "net/http" ) // AuthorsList is the handler to list authors func AuthorsList(c echo.Context) error { list, err := models.ListAuthors("") if err != nil { return c.JSON(http.StatusInternalServerError, models.Message{"Error getting authors"}) } return c.JSON(http.StatusOK, list) }