|
|
@ -123,7 +123,6 @@ export default class Render {
|
|
|
|
};
|
|
|
|
};
|
|
|
|
resolve(response);
|
|
|
|
resolve(response);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
//don't render delete pages
|
|
|
|
|
|
|
|
//check to see if deleted pages have been renderered and delete them
|
|
|
|
//check to see if deleted pages have been renderered and delete them
|
|
|
|
if (page.metadata.layout !== 'index') {
|
|
|
|
if (page.metadata.layout !== 'index') {
|
|
|
|
fs.unlink(
|
|
|
|
fs.unlink(
|
|
|
@ -134,8 +133,8 @@ export default class Render {
|
|
|
|
'.html'
|
|
|
|
'.html'
|
|
|
|
)
|
|
|
|
)
|
|
|
|
.then()
|
|
|
|
.then()
|
|
|
|
.catch(err => {
|
|
|
|
.catch(() => {
|
|
|
|
console.log('ERROR', err);
|
|
|
|
//console.log('ERROR', err);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -160,6 +159,7 @@ export default class Render {
|
|
|
|
for (let i = 0; i < pages.length; i++) {
|
|
|
|
for (let i = 0; i < pages.length; i++) {
|
|
|
|
let page = pages[i];
|
|
|
|
let page = pages[i];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//TODO: filter for deleted and unpublished pages
|
|
|
|
if (_.includes(page.metadata.tags, tag.tag_name)) {
|
|
|
|
if (_.includes(page.metadata.tags, tag.tag_name)) {
|
|
|
|
pageList.push({
|
|
|
|
pageList.push({
|
|
|
|
title: page.metadata.title,
|
|
|
|
title: page.metadata.title,
|
|
|
|