Create relative links for events

This commit is contained in:
ponas committed 2019-01-29 20:13:47 +01:00
1 parent 0f0eaa326e
commit 182640d5f8
1 file changed
+2 -1
+2 -1
View File
@@ -223,7 +223,8 @@ exports.onCreateNode = ({ node, actions, getNode }) => {
})
}
if (node.internal.type === 'wordpress__POST') {
if ((node.internal.type === 'wordpress__POST') ||
(node.internal.type === 'wordpress__EVENT')) {
const link = new URL(node.link).pathname
createNodeField({
node,