fix: normalize negative offset to zero in media filter
This commit is contained in:
@@ -659,6 +659,10 @@ func (mh *MediaHandler) ListMediaItemsFiltered(c echo.Context) error {
|
||||
limit = 50
|
||||
}
|
||||
|
||||
if offset < 0 {
|
||||
offset = 0
|
||||
}
|
||||
|
||||
if sort == "" {
|
||||
sort = "created_at DESC"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user