Skip to content

Commit d69f89e

Browse files
committed
fix: improve android connect pagination
1 parent c83c9dd commit d69f89e

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

bridge/bridge.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -275,8 +275,8 @@ type UserRelationships struct {
275275
type MyActivity struct {
276276
Action string `json:"action" xml:"action"`
277277
CreatedAt string `json:"created_at" xml:"created_at"`
278-
MaxPosition int64 `json:"max_position" xml:"max_position"`
279-
MinPosition int64 `json:"min_position" xml:"min_position"`
278+
MaxPosition string `json:"max_position" xml:"max_position"`
279+
MinPosition string `json:"min_position" xml:"min_position"`
280280
Sources []TwitterUser `json:"sources"`
281281
Targets []Tweet `json:"targets" xml:"targets"`
282282
TargetObjects []Tweet `json:"target_objects" xml:"target_objects"`

twitterv1/connect.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -251,8 +251,8 @@ func processNotificationGroup(group notificationGroup, userCache *sync.Map, post
251251
activity := &bridge.MyActivity{
252252
Action: getActionType(group.reason),
253253
CreatedAt: bridge.TwitterTimeConverter(first.IndexedAt),
254-
MinPosition: first.IndexedAt.UnixMilli(),
255-
MaxPosition: last.IndexedAt.UnixMilli(),
254+
MinPosition: strconv.FormatInt(first.IndexedAt.UnixMilli(), 10),
255+
MaxPosition: strconv.FormatInt(last.IndexedAt.UnixMilli(), 10),
256256
Sources: sources,
257257
Targets: []bridge.Tweet{},
258258
TargetObjects: []bridge.Tweet{},

0 commit comments

Comments
 (0)