mediabrowser: bump
imrpvoed UserNotFound error classification, no longer vulnerable to random 404s from proxies or whatever (for Jellyfin only, not emby)
This commit is contained in:
+16
-1
@@ -952,7 +952,7 @@ func (app *appContext) userSummary(jfUser mediabrowser.User) respUser {
|
||||
// @Success 200 {object} PageCountDTO
|
||||
// @Router /users/count [get]
|
||||
// @Security Bearer
|
||||
// @tags Activity,Statistics
|
||||
// @tags Users,Statistics
|
||||
func (app *appContext) GetUserCount(gc *gin.Context) {
|
||||
resp := PageCountDTO{}
|
||||
users, err := app.jf.GetUsers(false)
|
||||
@@ -965,6 +965,21 @@ func (app *appContext) GetUserCount(gc *gin.Context) {
|
||||
gc.JSON(200, resp)
|
||||
}
|
||||
|
||||
// @Summary Returns the list of all labels on accounts.
|
||||
// @Produce json
|
||||
// @Success 200 {object} LabelsDTO
|
||||
// @Router /users/labels [get]
|
||||
// @Security Bearer
|
||||
// @tags Users,Statistics
|
||||
func (app *appContext) GetLabels(gc *gin.Context) {
|
||||
if err := app.userCache.MaybeSync(app); err != nil {
|
||||
app.err.Printf(lm.FailedGetUsers, lm.Jellyfin, err)
|
||||
respond(500, "Couldn't get users", gc)
|
||||
return
|
||||
}
|
||||
gc.JSON(200, LabelsDTO{Labels: app.userCache.Labels})
|
||||
}
|
||||
|
||||
// @Summary Get a list of -all- Jellyfin users.
|
||||
// @Produce json
|
||||
// @Success 200 {object} getUsersDTO
|
||||
|
||||
Reference in New Issue
Block a user