mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-12-29 22:36:14 -06:00
small fix
This commit is contained in:
parent
4e054233da
commit
9b3e17b274
1 changed files with 12 additions and 0 deletions
|
|
@ -92,6 +92,12 @@ func (p *processor) PublicTimelineGet(ctx context.Context, authed *oauth.Auth, m
|
||||||
return nil, gtserror.NewErrorInternalError(err)
|
return nil, gtserror.NewErrorInternalError(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if len(s) == 0 {
|
||||||
|
return &apimodel.StatusTimelineResponse{
|
||||||
|
Statuses: []*apimodel.Status{},
|
||||||
|
}, nil
|
||||||
|
}
|
||||||
|
|
||||||
return p.packageStatusResponse(s, "api/v1/timelines/public", s[len(s)-1].ID, s[0].ID, limit)
|
return p.packageStatusResponse(s, "api/v1/timelines/public", s[len(s)-1].ID, s[0].ID, limit)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -113,6 +119,12 @@ func (p *processor) FavedTimelineGet(ctx context.Context, authed *oauth.Auth, ma
|
||||||
return nil, gtserror.NewErrorInternalError(err)
|
return nil, gtserror.NewErrorInternalError(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if len(s) == 0 {
|
||||||
|
return &apimodel.StatusTimelineResponse{
|
||||||
|
Statuses: []*apimodel.Status{},
|
||||||
|
}, nil
|
||||||
|
}
|
||||||
|
|
||||||
return p.packageStatusResponse(s, "api/v1/favourites", nextMaxID, prevMinID, limit)
|
return p.packageStatusResponse(s, "api/v1/favourites", nextMaxID, prevMinID, limit)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue