From 303bea15fdf5027ab07cb49c9b1add9b9f92eccb Mon Sep 17 00:00:00 2001 From: myl7 Date: Sat, 23 Jul 2022 14:38:33 +0000 Subject: [PATCH] add $ prefix for top param Suggested by OneDrive API doc: > be consistent throughout the request with your usage of > the $ character on these arguments --- pages/api/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/api/index.ts b/pages/api/index.ts index 5df1710..03a627d 100644 --- a/pages/api/index.ts +++ b/pages/api/index.ts @@ -257,7 +257,7 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse) params: { ...{ select: 'name,size,id,lastModifiedDateTime,folder,file,video,image', - top: siteConfig.maxItems, + $top: siteConfig.maxItems, }, ...(next ? { $skipToken: next } : {}), ...(sort ? { $orderby: sort } : {}),