diff --git a/CHANGELOG.md b/CHANGELOG.md index b5932c10a..9b6ab1528 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -44,6 +44,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - Bumped .NET Framework version to 4.6.2 as the 4.6.1 is not supported anymore. [#1856](https://github.com/pnp/powershell/pull/1856) - Changed `Add-PnPDataRowsToSiteTemplate`, it will now export a datetime field value as UTC string. [#1900](https://github.com/pnp/powershell/pull/1900) - The cmdlets `Remove-PnPFile`, `Remove-PnPFolder`, `Move-PnPListItemToRecycleBin`, `Remove-PnPList`, `Remove-PnPListItem` and `Remove-PnPPage` will now return the corresponding recycle bin item if they get deleted to the recycle bin. Before they would not return anything. [#1783](https://github.com/pnp/powershell/pull/1783) +- Changed `Get-PnPPlannerBucket` to return the buckets in the correct (reversed) order as you see them through the web interface [#1922](https://github.com/pnp/powershell/pull/1922) ### Fixed diff --git a/src/Commands/Utilities/PlannerUtility.cs b/src/Commands/Utilities/PlannerUtility.cs index 3af34d835..e0d8d4f6e 100644 --- a/src/Commands/Utilities/PlannerUtility.cs +++ b/src/Commands/Utilities/PlannerUtility.cs @@ -401,8 +401,7 @@ private static async Task ResolveGroupName(HttpClient httpClient, string public static async Task> GetBucketsAsync(HttpClient httpClient, string accessToken, string planId) { - var collection = await GraphHelper.GetResultCollectionAsync(httpClient, $"v1.0/planner/plans/{planId}/buckets", accessToken); - return collection.OrderBy(p => p.OrderHint); + return await GraphHelper.GetResultCollectionAsync(httpClient, $"v1.0/planner/plans/{planId}/buckets", accessToken); } public static async Task CreateBucketAsync(HttpClient httpClient, string accessToken, string name, string planId)