@tryghost/mg-ghost-api 0.4.27 → 0.5.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.
package/README.md CHANGED
@@ -88,7 +88,7 @@ See the [Filter documentation](https://docs.ghost.org/content-api/filtering) for
88
88
 
89
89
  ## Develop
90
90
 
91
- This is a mono repository, managed with [lerna](https://lerna.js.org).
91
+ This is a mono repository, managed with [Nx](https://nx.dev/) and yarn workspaces.
92
92
 
93
93
  Follow the instructions for the top-level repo.
94
94
  1. `git clone` this repo & `cd` into it as usual
package/lib/processor.js CHANGED
@@ -47,7 +47,14 @@ const processPost = (ghPost) => {
47
47
  };
48
48
 
49
49
  const processPosts = (posts) => {
50
- return posts.map(post => processPost(post));
50
+ const results = [];
51
+ for (let i = 0; i < posts.length; i++) {
52
+ const post = posts[i];
53
+ if (post) {
54
+ results.push(processPost(post));
55
+ }
56
+ }
57
+ return results;
51
58
  };
52
59
 
53
60
  const processAuthor = (ghAuthor) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tryghost/mg-ghost-api",
3
- "version": "0.4.27",
3
+ "version": "0.5.0",
4
4
  "repository": "https://github.com/TryGhost/migrate/tree/main/packages/mg-ghost-api",
5
5
  "author": "Ghost Foundation",
6
6
  "license": "MIT",
@@ -9,8 +9,8 @@
9
9
  "scripts": {
10
10
  "dev": "echo \"Implement me!\"",
11
11
  "test": "node --test 'test/**/*.test.js'",
12
- "lint": "eslint . --ext .js --cache",
13
- "posttest": "yarn lint"
12
+ "posttest": "yarn lint",
13
+ "lint": "eslint . --ext .js --cache"
14
14
  },
15
15
  "files": [
16
16
  "index.js",
@@ -24,6 +24,5 @@
24
24
  },
25
25
  "dependencies": {
26
26
  "@tryghost/admin-api": "1.14.6"
27
- },
28
- "gitHead": "e1680568191322d738c188f03298910aa3622735"
27
+ }
29
28
  }