Skip to content

Commit

Permalink
feat: 🎸 sitemap plugin will add origin from elder.config.js
Browse files Browse the repository at this point in the history
  • Loading branch information
Nick Reese committed Sep 18, 2020
1 parent ea1fc0e commit 9bbf144
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions packages/sitemap/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,13 @@ const plugin = {

if (plugin.config.origin && typeof plugin.config.origin === 'string' && plugin.config.origin.includes('://')) {
plugin.internal.ready = true;
} else if (
plugin.settings.origin &&
typeof plugin.settings.origin === 'string' &&
plugin.settings.origin.includes('://')
) {
plugin.internal.ready = true;
plugin.config.origin = plugin.settings.origin;
} else {
console.error(
`elder-plugin-sitemap please make sure you have a full domain name set for the value at 'elder-plugin-sitemap.origin' in your elder.config.js.`,
Expand Down

0 comments on commit 9bbf144

Please sign in to comment.