-
Notifications
You must be signed in to change notification settings - Fork 195
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GetComments() only return maximum of 30 comments. It used to return all comments. #1361
Comments
@larry-lau : from when did this we limit the amount of comments to 30? |
@jansenbe I am not 100% sure. I am looking at the pnpcore code and it is just making HTTP GET on the SharePoint REST API _api/web/lists(guid'{List.Id}')/getitembyid({Id})/getcomments and I didn't see any limit imposed there. I am curious if it should have pagination logic to fetch all comments. |
@larry-lau : or some server side change. Can you capture the REST query and see if it returns all items when you invoke it directly? |
@jansenbe: The response doesn't returns all items but it does return odata.nextLink which we could use to fetch more data https://xxx.sharepoint.com/sites/TestNews1Edited/_api/web/lists(guid%27aec597d6-13ea-4f08-9b41-a03c19200281%27)/getitembyid(8)/getcomments?%24skiptoken=AAAAABAAAAAAAAAA8FapEvIg3Eg1 I am curious if the pnpcore sdk could support following the odata.nextLink to fetch all comments. |
@larry-lau : I've reprod this at my side as well (thanks for sharing the test case!). Will see if I can get this one fixed. |
@larry-lau : and the issue is fixed, fix will be next nightly, so closing this now. Seems as the API implementation changed and now uses paging by 30 items |
Category
Describe the bug
GetComments() used to return all comments. Now it is only returning 30 comments.
Steps to reproduce
Expected behavior
GetComments() should return all comments like it used to.
Environment details (development & target environment)
Additional context
Thanks for your contribution! Sharing is caring.
The text was updated successfully, but these errors were encountered: