diff --git a/csharp/Squidex.ClientLibrary/Squidex.ClientLibrary/SquidexClientExtensions.cs b/csharp/Squidex.ClientLibrary/Squidex.ClientLibrary/SquidexClientExtensions.cs index 94e2a442..20f7933b 100644 --- a/csharp/Squidex.ClientLibrary/Squidex.ClientLibrary/SquidexClientExtensions.cs +++ b/csharp/Squidex.ClientLibrary/Squidex.ClientLibrary/SquidexClientExtensions.cs @@ -25,7 +25,7 @@ public static async Task> GetAllAsync> GetAllAsync GetAllAssetsAsync(this SquidexAssetClient assetClient, int batchSize = 200) { - var query = new ODataQuery { Top = batchSize }; + var query = new ODataQuery { Top = batchSize, Skip = 0 }; var entities = new AssetEntities(); do @@ -44,7 +44,7 @@ public static async Task GetAllAssetsAsync(this SquidexAssetClien entities.Total = getResult.Total; entities.Items.AddRange(getResult.Items); - query.Skip += entities.Items.Count; + query.Skip = entities.Items.Count; } while (query.Skip < entities.Total);