mirror of
https://gitea.phreedom.club/localhost_frssoft/bloat.git
synced 2025-05-05 03:18:44 +00:00
Add likes list
This commit is contained in:
parent
59692b7155
commit
2b1c703b6c
2 changed files with 21 additions and 0 deletions
|
@ -541,6 +541,18 @@ func (svc *service) ServeUserPage(c *model.Client, id string, pageType string,
|
|||
nextLink = fmt.Sprintf("/user/%s/blocks?max_id=%s",
|
||||
id, pg.MaxID)
|
||||
}
|
||||
case "likes":
|
||||
if !isCurrent {
|
||||
return errInvalidArgument
|
||||
}
|
||||
statuses, err = c.GetFavourites(ctx, &pg)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
if len(statuses) == 20 && len(pg.MaxID) > 0 {
|
||||
nextLink = fmt.Sprintf("/user/%s/likes?max_id=%s",
|
||||
id, pg.MaxID)
|
||||
}
|
||||
default:
|
||||
return errInvalidArgument
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue