Add $top param for drive pagers (#4619)

<!-- PR description-->

Closes https://github.com/alcionai/corso/issues/4614 


---

#### Does this PR need a docs update or release note?

- [ ]  Yes, it's included
- [ ] 🕐 Yes, but in a later PR
- [x]  No

#### Type of change

<!--- Please check the type of change your PR introduces: --->
- [ ] 🌻 Feature
- [x] 🐛 Bugfix
- [ ] 🗺️ Documentation
- [ ] 🤖 Supportability/Tests
- [ ] 💻 CI/Deployment
- [ ] 🧹 Tech Debt/Cleanup

#### Issue(s)

<!-- Can reference multiple issues. Use one of the following "magic words" - "closes, fixes" to auto-close the Github issue. -->
* #<issue>

#### Test Plan

<!-- How will this be tested prior to merging.-->
- [x] 💪 Manual
- [ ]  Unit test
- [ ] 💚 E2E
This commit is contained in:
Abhishek Pandey 2023-11-06 23:22:29 -08:00 committed by GitHub
parent ea6a57b2a5
commit ec1afa8c84
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -38,7 +38,9 @@ func (c Drives) NewDriveItemPager(
selectProps ...string,
) pagers.NonDeltaHandler[models.DriveItemable] {
options := &drives.ItemItemsItemChildrenRequestBuilderGetRequestConfiguration{
QueryParameters: &drives.ItemItemsItemChildrenRequestBuilderGetQueryParameters{},
QueryParameters: &drives.ItemItemsItemChildrenRequestBuilderGetQueryParameters{
Top: ptr.To(maxNonDeltaPageSize),
},
}
if len(selectProps) > 0 {
@ -145,7 +147,9 @@ func (c Drives) newDriveItemDeltaPager(
options := &drives.ItemItemsItemDeltaRequestBuilderGetRequestConfiguration{
Headers: newPreferHeaders(preferHeaderItems...),
QueryParameters: &drives.ItemItemsItemDeltaRequestBuilderGetQueryParameters{},
QueryParameters: &drives.ItemItemsItemDeltaRequestBuilderGetQueryParameters{
Top: ptr.To(maxDeltaPageSize),
},
}
if len(cc.Select) > 0 {