diff options
Diffstat (limited to 'modules/lists')
-rw-r--r-- | modules/lists/lists.go | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/modules/lists/lists.go b/modules/lists/lists.go index 67856fe..ee0eb68 100644 --- a/modules/lists/lists.go +++ b/modules/lists/lists.go | |||
@@ -499,13 +499,21 @@ func (m *Module) APIgetUserLists(w http.ResponseWriter, r *http.Request, p httpr | |||
499 | } | 499 | } |
500 | 500 | ||
501 | lists := m.GetUserLists(user, false) | 501 | lists := m.GetUserLists(user, false) |
502 | var pubLists []List | ||
502 | 503 | ||
503 | for _, list := range lists { | 504 | for _, list := range lists { |
504 | // owner wegen SICHERHEIT rausfiltern (nodumppassword2k16) | 505 | // owner wegen SICHERHEIT rausfiltern (nodumppassword2k16) |
505 | list.Owner = nil | 506 | // list.Owner = nil |
507 | var tempList List | ||
508 | tempList.Description = list.Description | ||
509 | tempList.ForkOf = list.ForkOf | ||
510 | tempList.ID = list.ID | ||
511 | tempList.Name = list.Name | ||
512 | tempList.UpdatedAt = list.UpdatedAt | ||
513 | pubLists = append(pubLists, tempList) | ||
506 | } | 514 | } |
507 | 515 | ||
508 | data, err := json.Marshal(&lists) | 516 | data, err := json.Marshal(&pubLists) |
509 | if err != nil { | 517 | if err != nil { |
510 | log.Println(err) | 518 | log.Println(err) |
511 | http.Error(w, "500", http.StatusInternalServerError) | 519 | http.Error(w, "500", http.StatusInternalServerError) |