Commit b7a06c5a authored by Antonin COQUET's avatar Antonin COQUET
Browse files

fix: minor fix on posts images script

parent 6b4cb2f3
Pipeline #12389 passed with stage
in 2 minutes and 3 seconds
......@@ -110,6 +110,7 @@ async function uploadPostImage(imagePath)
return url.url;
}).catch((error) => {
console.error(error);
return null
})
}
......@@ -136,7 +137,7 @@ async function createPosts(deleteOnly) {
_.forEach(postsData, async (post) => {
//upload de l'image en featured_image
if (post.feature_image) {
post.feature_image = await uploadPostImage(post.feature_image).catch(() => null);
post.feature_image = await uploadPostImage(post.feature_image);
}
api.posts
.add(post, { source: 'html' })
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment