mirror of
https://github.com/knadh/listmonk.git
synced 2025-02-25 23:06:17 +08:00
Default to empty list instead of nil in media response
This commit is contained in:
parent
693b939a72
commit
a03c7bd7c9
1 changed files with 1 additions and 1 deletions
2
media.go
2
media.go
|
@ -112,7 +112,7 @@ func handleUploadMedia(c echo.Context) error {
|
|||
func handleGetMedia(c echo.Context) error {
|
||||
var (
|
||||
app = c.Get("app").(*App)
|
||||
out []media.Media
|
||||
out = []media.Media{}
|
||||
)
|
||||
|
||||
if err := app.queries.GetMedia.Select(&out); err != nil {
|
||||
|
|
Loading…
Reference in a new issue