mirror of
https://github.com/d0zingcat/NotionNext.git
synced 2026-05-14 07:26:52 +00:00
build fix
This commit is contained in:
@@ -157,8 +157,8 @@ export async function getConfigMapFromConfigPage(allPages) {
|
||||
// 只导入生效的配置
|
||||
if (config.enable) {
|
||||
// console.log('[Notion配置]', config.key, config.value)
|
||||
notionConfig[config.key] = config.value || ''
|
||||
// 配置不能是undefined,至少是空字符串
|
||||
notionConfig[config.key] = config.value || null
|
||||
// 配置不能是undefined,至少是null
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -245,12 +245,15 @@ function generateCustomizeSlug(postProperties, NOTION_CONFIG) {
|
||||
let fullPrefix = ''
|
||||
let allSlugPatterns = NOTION_CONFIG?.POST_URL_PREFIX
|
||||
if (allSlugPatterns === undefined) {
|
||||
allSlugPatterns = siteConfig('POST_URL_PREFIX', '', NOTION_CONFIG).split(
|
||||
'/'
|
||||
)
|
||||
allSlugPatterns = siteConfig(
|
||||
'POST_URL_PREFIX',
|
||||
BLOG.POST_URL_PREFIX,
|
||||
NOTION_CONFIG
|
||||
).split('/')
|
||||
} else {
|
||||
allSlugPatterns = allSlugPatterns.split('/')
|
||||
}
|
||||
|
||||
const POST_URL_PREFIX_MAPPING_CATEGORY = siteConfig(
|
||||
'POST_URL_PREFIX_MAPPING_CATEGORY',
|
||||
{},
|
||||
|
||||
Reference in New Issue
Block a user