storyblok 3.10.4 → 3.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,8 @@
1
+ app.storyblok:
2
+ - '[x] *app.storyblok.com'
3
+ api.storyblok:
4
+ - '[x] *api.storyblok.com'
5
+ mapi.storyblok:
6
+ - '[x] *mapi.storyblok.com'
7
+ capi.storyblok:
8
+ - '[x] *capi.storyblok.com'
@@ -0,0 +1,14 @@
1
+ name: "Issue Labeler"
2
+ on:
3
+ issues:
4
+ types: [opened]
5
+
6
+ jobs:
7
+ triage:
8
+ runs-on: ubuntu-latest
9
+ steps:
10
+ - uses: github/issue-labeler@v2.5
11
+ with:
12
+ repo-token: "${{ secrets.GITHUB_TOKEN }}"
13
+ configuration-path: .github/labeler.yml
14
+ enable-versioned-regex: 0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "storyblok",
3
- "version": "3.10.4",
3
+ "version": "3.11.0",
4
4
  "description": "A simple CLI to start Storyblok from your command line.",
5
5
  "keywords": [
6
6
  "storyblok",
@@ -45,10 +45,10 @@ class SyncDatasources {
45
45
  try {
46
46
  const entriesFirstPage = await this.client.get(`spaces/${spaceId}/datasource_entries/?datasource_id=${datasourceId}`)
47
47
  const entriesRequets = []
48
- for (let i = 1; i < Math.ceil(entriesFirstPage.total / 25); i++) {
48
+ for (let i = 2; i <= Math.ceil(entriesFirstPage.total / 25); i++) {
49
49
  entriesRequets.push(this.client.get(`spaces/${spaceId}/datasource_entries/?datasource_id=${datasourceId}`, { page: i }))
50
50
  }
51
- return entriesFirstPage.data.datasource_entries.concat((await Promise.all(entriesRequets)).map(r => r.data.datasource_entries))
51
+ return entriesFirstPage.data.datasource_entries.concat(...(await Promise.all(entriesRequets)).map(r => r.data.datasource_entries))
52
52
  } catch (err) {
53
53
  console.error(`An error ocurred when loading the entries of the datasource #${datasourceId}: ${err.message}`)
54
54